NameError in WelcomeController#index

Steps to reproduce

cd [app directory]
rails server
open localhost:3000/welcome/index

(Guidelines for creating a bug report are available
here
)

Expected behavior

I should be able to see the login screen for our ROR App (pcms.herokuapps.com)

Actual behavior

45 46 47 48 49 50
def deny_access session[:forward_to] = request.fullpath redirect_to login_url end def check_admin
enter image description here

How to I get to the ROR app. Like it looks like the live site.

https://pcms.herokuapp.com/login

The app was designed by a previous developer in 2013. I just received the files two weeks ago. Having to update everything to latest versions of everything. I’ve added the database into the pgAdmin4.

I need to be able to see the changes in the localhost before pushing to heroku platform.

routes.rb


YES I am in the App Directory

System configuration

Rails version:
Rails 5.2.0
Ruby version:
ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-darwin17]

Steps to reproduce

USING POSTGRESQL

1) Did it run locally with the original versions of "everything"?
2) Did the tests all pass originally?
3) Do the tests pass now?
4) Are there errors in the console when you start the app?

Yes the original version ran fine. No errors. Just had to updated rails, ruby, gems, etc since the app is still running on the original version, and the platform asked us to update several things.

Yes the original version ran fine. No errors. Just had to updated rails,
ruby, gems, etc since the app is still running on the original version, and
the platform asked us to update several things.

You have answered question 1 but not 2, 3 or 4.

Colin

Yes the original version ran fine. No errors. Just had to updated rails,
ruby, gems, etc since the app is still running on the original version, and
the platform asked us to update several things.

That answered *1* question...

Yes ran locally with the original versions of everything. Yes all the test passed.

Currently the only error is on the Welcome Controller.

No errors in the console

If there's a problem I'd expect it in the console or in the development
log file.

Where is this "error" you're seeing? Can you paste it in here?

ERROR

localhost:3000/welcome/index

NameError in WelcomeController#index

undefined local variable or method `login_url’ for #WelcomeController:0x00007fa9da705068

Extracted source (around line #47):

45
46
47
48
49
50
def deny_access

session[:forward_to] = request.fullpath

redirect_to login_url

end

def check_admin

`Rails.root: /Users/snowflake/Documents/Current Website/pcms`

So does 'login' show up when you run `rake routes`? How are you
authenticating?

$rails routes

WARNING: Nokogiri was built against LibXML version 2.9.4, but has dynamically loaded 2.8.0

** Invoke routes (first_time)

** Invoke environment (first_time)

** Execute environment

** Execute routes

Prefix Verb URI Pattern Controller#Action

welcome_index GET /welcome/index(.:format) welcome#index

rails_service_blob GET /rails/active_storage/blobs/:signed_id/*filename(.:format) active_storage/blobs#show

rails_blob_representation GET /rails/active_storage/representations/:signed_blob_id/:variation_key/*filename(.:format) active_storage/representations#show

rails_disk_service GET /rails/active_storage/disk/:encoded_key/*filename(.:format) active_storage/disk#show

update_rails_disk_service PUT /rails/active_storage/disk/:encoded_token(.:format) active_storage/disk#update

rails_direct_uploads POST /rails/active_storage/direct_uploads(.:format)

Rails.application.routes.draw do

get ‘welcome/index’

resources :feedbacks, only: [:post]