From 714f264d62c5d2a45efc4b013f2fca1eb7eff1f1 Mon Sep 17 00:00:00 2001 From: Michael Kozono Date: Mon, 2 Oct 2017 15:00:50 -0700 Subject: Rename method to `to_normalized_s` --- db/post_migrate/20170921101004_normalize_ldap_extern_uids.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'db') diff --git a/db/post_migrate/20170921101004_normalize_ldap_extern_uids.rb b/db/post_migrate/20170921101004_normalize_ldap_extern_uids.rb index 501ba7c5fe2..aa95fa49e48 100644 --- a/db/post_migrate/20170921101004_normalize_ldap_extern_uids.rb +++ b/db/post_migrate/20170921101004_normalize_ldap_extern_uids.rb @@ -220,7 +220,7 @@ class NormalizeLdapExternUids < ActiveRecord::Migration ## # Return the DN as an escaped and normalized string. - def to_s_normalized + def to_normalized_s self.class.new(*to_a).to_s end @@ -270,7 +270,7 @@ class NormalizeLdapExternUids < ActiveRecord::Migration ldap_identities = Identity.where("provider like 'ldap%'") ldap_identities.find_each do |identity| begin - identity.extern_uid = Gitlab::LDAP::DN.new(identity.extern_uid).to_s_normalized + identity.extern_uid = Gitlab::LDAP::DN.new(identity.extern_uid).to_normalized_s unless identity.save say "Unable to normalize \"#{identity.extern_uid}\". Skipping." end -- cgit v1.2.1