class Pagy::VariableError

generic variable error

Attributes

pagy[R]

Public Class Methods

new(pagy) click to toggle source
Calls superclass method
# File lib/pagy/exceptions.rb, line 9
def initialize(pagy)
  super
  @pagy = pagy
end

Public Instance Methods

value() click to toggle source
# File lib/pagy/exceptions.rb, line 19
def value
  pagy.vars[variable]
end
variable() click to toggle source
# File lib/pagy/exceptions.rb, line 14
def variable
  message =~ /expected :(\w+)/
  Regexp.last_match(1)&.to_sym
end