1
0
Fork 0
forked from OpenNeo/impress
impress/app/controllers
Emi Matchu dc44b4dbb3 Oops, fix bug with saving outfits of pets loaded from Neopets.com
Okay right, the wardrobe-2020 app treats `state` as a bit of an
override thing, and `pose` is the main canonical field for how a pet
looks. We were missing a few pieces here:

1. After loading a pet, we weren't including the `pose` field in the
   initial query string for the wardrobe URL, but we _were_ including
   the `state` field, so the outfit would get set up with a conflicting
   pet state ID vs pose.
2. When saving an outfit, we weren't taking the `state` field into
   account at all. This could cause the saved outfit to not quite match
   how it actually looked in-app, because the default pet state for
   that species/color/pose trio could be different; and regardless, the
   outfit state would come back with `appearanceId` set to `null`,
   which wouldn't match the local outfit state, which would trigger an
   infinite loop.

Here, we complete the round-trip of the `state` field, from pet loading
to outfit saving to the outfit data that comes back after saving!
2024-02-08 09:51:31 -08:00
..
alt_styles_controller.rb
application_controller.rb Add mini profiler to each page 2023-10-27 19:38:49 -07:00
campaigns_controller.rb new donate layout for post-2017 campaign 2018-01-18 17:14:02 -08:00
closet_hangers_controller.rb
closet_lists_controller.rb
contributions_controller.rb
donation_features_controller.rb
donations_controller.rb Use flash[:notice] instead of flash[:success] 2023-10-23 19:05:07 -07:00
item_appearances_controller.rb
item_trades_controller.rb
items_controller.rb
locales_controller.rb
neopets_connections_controller.rb
neopets_page_import_tasks_controller.rb
outfits_controller.rb Oops, fix bug with saving outfits of pets loaded from Neopets.com 2024-02-08 09:51:31 -08:00
pet_types_controller.rb Remove references to species/color translations at call sites 2024-01-23 05:23:57 -08:00
pets_controller.rb
sitemap_controller.rb
static_controller.rb
users_controller.rb