You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But it's returning null response, and doesn't seem to be working.
[active_model_serializers] Rendered ActiveModel::Serializer::Null with Panko::Response.
The text was updated successfully, but these errors were encountered:
AMS has facility to pass additional parameters to serializer
i.e, render json: user, include_token: true, current_user_id: user.id
It would be nice if we have similar feature to add additional parameters on Panko for both single object serializer and array serializers,
render json: Panko::UserSerializer.new.serialize_to_json(user)
render json: Panko::ArraySerializer.new(users, each_serializer: Panko::UserSerializer)
Currently it just accepts 1 parameters to be passed on
Tried using,
render json: Panko::Response.new(
current_user_id: user.id,
include_token: true,
user: Panko::UserSerializer.new.serialize_to_json(user)
)
But it's returning null response, and doesn't seem to be working.
[active_model_serializers] Rendered ActiveModel::Serializer::Null with Panko::Response.
The text was updated successfully, but these errors were encountered: