fcmpush
fcmpush copied to clipboard
Raise custom error if missing configuration
This is an improvement suggestion.
How?
- #push method is called
- config.json_key_io is nil
- Some Google's env var is nil
Reference: https://github.com/miyataka/fcmpush#usage
What?
The following error is raised:
NoMethodError:
undefined method `gsub' for nil:NilClass
Suggestion
Rescue the NoMethodError and raises a custom error with information regarding the missing configuration
Thanks for your time and for the good work.
@LucasCarrias Thanks for your suggestion. That's sounds good. It helps that fcmpush newbie.