More generously catch errors on userlookup
Okay so, userlookup stuff hasn't worked in years, because it requires a login now.
But apparently, somewhere recently, the code inside our `neopets` gem started hard crashing, because of assumptions we made about the document we'd get back.
I'm not sure why it only recently started crashing? or if I'm even necessarily right about that?
But anyway, I'm just doing the easiest safest (🤞🏻) change possible: being more generous with the errors we swallow.
Test Plan:
Deploy and cross fingers.
This commit is contained in:
parent
c7d60e3e41
commit
6697b15413
1 changed files with 1 additions and 1 deletions
|
@ -109,7 +109,7 @@ class PetState < ActiveRecord::Base
|
||||||
self.female = user_pet.female?
|
self.female = user_pet.female?
|
||||||
self.mood_id = user_pet.mood.id
|
self.mood_id = user_pet.mood.id
|
||||||
self.labeled = true
|
self.labeled = true
|
||||||
rescue Neopets::User::Error
|
rescue
|
||||||
# If there's an error loading the userlookup data (e.g. account is
|
# If there's an error loading the userlookup data (e.g. account is
|
||||||
# frozen), no big deal; we just won't label the pet right now. Proceed
|
# frozen), no big deal; we just won't label the pet right now. Proceed
|
||||||
# as usual.
|
# as usual.
|
||||||
|
|
Loading…
Reference in a new issue