Uninitialized gem constant

I installed the JWT gem - https://github.com/progrium/ruby-jwt Of course there is gem 'jwt'

in Gemfile

. Regardless, I have an error

uninitialized constant HomeController::JWT

      

in HomeController

class HomeController < ApplicationController

 def method1
   @jwt_token = JWT.encode({.... })
 end

end

      

+3
ruby ruby-on-rails ruby-on-rails-3.2


source to share


1 answer


I believe what you need require 'jwt'

.



NTN

+2


source to share







All Articles
Loading...
X
Show
Funny
Dev
Pics