I have defined a script with the following code snippet:
check_params param
def check_params(param)
# some code
end
When I run this I get
undefined method `check_params' for main:Object (NoMethodError)
Ruby expects the method to be declared before you call it, try to move your method definition before you call the method like:
def check_params(param)
# some code
end
check_params param
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With