I have an object that holds alerts and some information about them:
var alerts = {
1: { app: \'helloworld\', message: \'message\' },
2: { app: \'hel
Do you have the ability to change the outer-most structure to an array? So it would look like this
var alerts = [{"app":"helloworld","message":null},{"app":"helloagain","message":"another message"}];
So when you needed to add one, you can just push it onto the array
alerts.push( {"app":"goodbyeworld","message":"cya"} );
Then you have a built-in zero-based index for how the errors are enumerated.