NoMethodError

Tourist
12 0 1

I am developing a public app using ruby on rails.  I generated the app with the shopify_app gem and have already linked it to my store with the appropriate API information.  Up until now, I have been able to see the standard page of 10 products listed when I visit localhost:3000.  Today, even though I have not changed the code in my appplication at all, I'm getting the error:

NoMethodError in ShopifyApp::SessionsController#callback

undefined method `[]' for nil:NilClass

I don't understand this issue.  The problem seems to be that there is no callback method defined in the sessions controller, but up until now, that hasn't been an issue.  The app would normally follow the callback url that I set in the app settings in my partner account, which is localhost:3000.  The only thing that I have done regarding the app in the last week is make an API call via shopify-cli to create and save a script tag.  Does anyone know how to resolve this issue?

Thanks.

0 Likes
Shopify Partner
53 2 16

I encountered this error

 

/usr/local/Cellar/shopify-cli/1.0.4/src/lib/shopify-cli/tasks/update_dashboard_urls.rb:12:in `call': undefined method `[]' for nil:NilClass (NoMethodError)

 


When I logged in using the wrong account.

I did:

 

❯ shopify logout
❯ shopify serve
𝒾 Authentication required. Login to the URL below with your Shopify Partners account credentials to continue.
Please open this URL in your browser:
https://accounts.shopify.com/oauth/authorize?client_id=fbx1236...

 


Then I clicked the link and logged in using the right Partner account, and everything was fine again.

Just trying to help out.

We are web app developers, SEO ethousiasts, and do all kinds of other cool internet things.
Check us out at https://public-apps.com
0 Likes