Skip to content

Instantly share code, notes, and snippets.

@mmagm
Last active August 29, 2015 13:56
Show Gist options
  • Save mmagm/9324880 to your computer and use it in GitHub Desktop.
Save mmagm/9324880 to your computer and use it in GitHub Desktop.
require 'devise'
class TestToken
def self.token
@token ||= Devise.friendly_token
end
end
class TestToken2 < TestToken
end
puts TestToken.token
puts TestToken2.token
class TestToken
def self.token
@@token ||= Devise.friendly_token
end
end
class TestToken2 < TestToken
end
puts TestToken.token
puts TestToken2.token
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment