discourse/app/assets
Dan Ungureanu 03ad88f2c2
FIX: Add errors field if group update confirmation (#16260)
* FIX: Redirect if Discourse-Xhr-Redirect is present

`handleRedirect` was passed an wrong argument type (a string) instead of
a jqXHR object and missed the fields checked in condition, thus always
evaluating to `false`.

* FIX: Add `errors` field if group update confirmation

An explicit confirmation about the effect of the group update is
required if the default notification level changes. Previously, if the
confirmation was missing the API endpoint failed silently returning
a 200 response code and a `user_count` field. This change ensures that
a proper error code is returned (422), a descriptive error message and
the additional information in the `user_count` field.

This commit also refactors the API endpoint to use the
`Discourse-Xhr-Redirect` header to redirect the user if the group is
no longer visible.
2022-03-24 14:50:44 +02:00
..
images FEATURE: Update push notification icons (#16206) 2022-03-16 16:21:44 -03:00
javascripts FIX: Add errors field if group update confirmation (#16260) 2022-03-24 14:50:44 +02:00
stylesheets A11Y: Focus last viewed topic in topic lists (take 3) (#16257) 2022-03-23 13:03:56 +03:00