utils: When serializing a dict object, return a dict of the same values (serialized), instead of just a list of the keys
Daniel Barnes
Branch: nasonfish/panel2:master
Branch: tortoiselabs/panel2:master
Merged
Merged pull request
Merged in nasonfish/panel2 (pull request #5)
[As you may have heard, I'm working with both panel2 and the TortoiseLabs API a bit, so I'll be trying to patch whatever issues I run into.]
The possible templates for deploying a VPS are stored in a dict, and when that is passed to the render_template_or_json() for the API, it's being serialized as a list - the function iterates through the keys and stores them in a list.
This will check if the object is a dict, and if so, and treat it as such.