diff options
author | Robin Houston <robin.houston@gmail.com> | 2012-07-02 15:21:09 +0100 |
---|---|---|
committer | Robin Houston <robin.houston@gmail.com> | 2012-07-02 15:21:09 +0100 |
commit | b479373671365ba9377c23a8e984606ddab13330 (patch) | |
tree | 78b7a9a82a38ff7cb9818cf210c2bb6b60402472 | |
parent | b25e9084f46787a495891257236fd26fbd2ff36a (diff) |
Use 33 bytes consistently
Let’s use 33 bytes consistently for the API key, to avoid an = pad
at the end when it’s base64-encoded.
-rw-r--r-- | app/models/public_body.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/public_body.rb b/app/models/public_body.rb index a372de435..bc8f084bb 100644 --- a/app/models/public_body.rb +++ b/app/models/public_body.rb @@ -95,7 +95,7 @@ class PublicBody < ActiveRecord::Base self.publication_scheme = "" if self.publication_scheme.nil? # Set an API key if there isn’t one - self.api_key = SecureRandom.base64(32) if self.api_key.nil? + self.api_key = SecureRandom.base64(33) if self.api_key.nil? end # like find_by_url_name but also search historic url_name if none found |