AceMetrix/jquery-deparam

converts empty object into a string

Closed this issue · 2 comments

Not sure if this was done intentionally, but I'd expect that if I started with an object, I'd be able to get that returned as an object.

Interesting..

I just tried $.param({}) and it becomes an empty string
$.param('') is also an empty string

There's actually no way to tell those 2 apart unfortunately, as information is lost

For now, I'll document the shortcoming, you may have to find a workaround. I'm happy to accomodate this case if you can think of a way to do it.