Class: Flexite::Diff::Token

Inherits:
Object
  • Object
show all
Defined in:
app/services/flexite/diff/token.rb

Instance Method Summary collapse

Constructor Details

#initialize(string_token) ⇒ Token

Returns a new instance of Token.



4
5
6
# File 'app/services/flexite/diff/token.rb', line 4

def initialize(string_token)
  @token = string_token
end

Instance Method Details

#invalid?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'app/services/flexite/diff/token.rb', line 12

def invalid?
  !valid?
end

#valid?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'app/services/flexite/diff/token.rb', line 8

def valid?
  secure_compare(Flexite.config.migration_token, @token)
end