function createObject(argName, argProperties){
var object = {};
object[argName] = argProperties;
}
I am calling my function in the following manner.
createObject('name', objectProperties);
The issue I am encountering is with the structure of the resulting object. It currently looks like this:
{"argName":{"Properties":"Value"}}
My desired output would be as follows. This is a general class that I am using to create multiple request objects.
{"name":{"Properties":"Value"}}