foreman_discovery icon indicating copy to clipboard operation
foreman_discovery copied to clipboard

Fix rails constants warning

Open sbernhard opened this issue 2 years ago • 2 comments

This fixes: lib/foreman_discovery/engine.rb:302: warning: already initialized constant ForemanDiscovery::Engine::MANAGER lib/foreman_discovery/engine.rb:271: warning: previous definition of MANAGER was here

sbernhard avatar Mar 05 '24 08:03 sbernhard

@ofedoren do you agree?

I guess? If it were me I would get rid of those constants unless they are used somewhere else. Even though REX plugin does the same thing and it already has app.reloader.to_prepare, so it works, I'd remove them. There is no much point to use constants here...

ofedoren avatar Dec 06 '24 13:12 ofedoren

Oh, good point. They really are "constants" because they're not frozen.

ekohl avatar Dec 06 '24 14:12 ekohl