sequel_vault 0.5 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5786aa527d01d7c5bd4df1a1782a5522337c27e2
4
- data.tar.gz: dab2b2ca481ca80a15e670635f7267c29e76f931
3
+ metadata.gz: b25cbb20daa90e19edede27f8b8235df3886cb64
4
+ data.tar.gz: 279a8a6f990c269bdc779aa78cfe83c57f1a511d
5
5
  SHA512:
6
- metadata.gz: 922ebf91834853e1188f8973d8c655ef2e5d86352626701cd2406b439d45888183ab32c86cce2e41a0e5a71ff0705be0f15764896f8a25ceab1795ff87c3b658
7
- data.tar.gz: 862f5d2cbe3ca630807e3cb444d35bbd1157e941130db4379067816fb0af770ed86401726d1c4e05b7ce60834088c1ca13a9fdd00cd481394c6401ce37b4becf
6
+ metadata.gz: 127014206cd81bf6ac66da42101f346be518ab2ac13cef3ccdc6bab8743e4901bd20e067248ae554ed3ff457f26f360d68731fe96ee94ce1ae68287fa60d2b56
7
+ data.tar.gz: f0a071aca60a7f582c24dc477d2ad1b33a0a162d07b259b4d11f3a244a307b15e0ffa160af12d075dc1dbde8def142f873d5c0403dad118520b973b4b7745910
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sequel_vault (0.4)
4
+ sequel_vault (0.5.1)
5
5
  fernet (~> 2.1, >= 2.1)
6
6
  sequel (~> 4.21, >= 4.21.0)
7
7
 
data/lib/sequel_vault.rb CHANGED
@@ -80,8 +80,8 @@ module Sequel
80
80
  module InstanceMethods
81
81
  def []=(attr, plain)
82
82
  if model.vault_attrs.include?(attr) && !plain.nil?
83
- send("#{attr}_digest=", self.class.digest(model.vault_keys, plain)) if model.columns.include?(:"#{attr}_digest")
84
- send("key_id=", model.vault_keys.length) if model.columns.include?(:key_id)
83
+ send("#{attr}_digest=", self.class.digest(model.vault_keys, plain)) if respond_to?("#{attr}_digest=")
84
+ send("key_id=", model.vault_keys.length) if respond_to?("key_id=")
85
85
  value = self.class.encrypt(model.vault_keys, plain)
86
86
  end
87
87
  super(attr, value || plain)
data/sequel_vault.gemspec CHANGED
@@ -13,7 +13,7 @@ Gem::Specification.new do |gem|
13
13
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
14
14
  gem.name = "sequel_vault"
15
15
  gem.require_paths = ["lib"]
16
- gem.version = '0.5'
16
+ gem.version = '0.5.1'
17
17
 
18
18
  gem.add_runtime_dependency 'sequel', '~> 4.21', '>= 4.21.0'
19
19
  gem.add_runtime_dependency 'fernet', '~> 2.1', '>= 2.1'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sequel_vault
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.5'
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Timothée Peignier
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-20 00:00:00.000000000 Z
11
+ date: 2015-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sequel
@@ -149,4 +149,3 @@ summary: Handle attributes encryption.
149
149
  test_files:
150
150
  - spec/sequel_vault_spec.rb
151
151
  - spec/spec_helper.rb
152
- has_rdoc: