IanMitchell / discord-notifier

A ruby wrapper around Discord webhooks
MIT License
14 stars 4 forks source link

uninitialized constant Discord (NameError) #8

Closed ezuhaib closed 6 years ago

ezuhaib commented 6 years ago

I get the error uninitialized constant Discord (NameError) (in console) upon trying to start my Rails server after having added the discord-notifier gem, and the initializer. I am using ruby 2.4.2 and rails 5.1.

IanMitchell commented 6 years ago

Yeah, I'm seeing this too 😢. Swear it was working at one point - little new to gem development so I dunno how quick I'll be with a fix, but looking at it now

IanMitchell commented 6 years ago

Looks like you can use

require 'discord_notifier'

Discord::Notifier.setup do |config|
  ...
end

to unblock yourself for the meantime - still trying to figure out how to get the autoloading sorted out

IanMitchell commented 6 years ago

Alright, think I got it fixed! If version 1.0.1 doesn't work, let me know 😄. Thanks for the bug report!