musacivak / rock-php

Automatically exported from code.google.com/p/rock-php
0 stars 0 forks source link

Empty objects interpreted and persisted as arrays #142

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
1.Create a document such as
{
  "foo":"foo"
  "bar":{}
}
2. View the record in rockmongo

Expected output:
{
  "foo":"foo"
  "bar":{}
}
Actual:
{
  "foo":"foo"
  "bar":[]
}

3. Additionally, if the document is updated it is persisted with an empty array 
instead of an object. This is true when another key/value is update or the 
empty array, even if you replace the array with an empty object it is persisted 
as an array.

Ubuntu 10.04/PHP 5.3.2/pymongo 1.1.4/MongoDB 1.8.1

Original issue reported on code.google.com by matt.sma...@gmail.com on 20 May 2011 at 4:37

GoogleCodeExporter commented 8 years ago
I have the same issue.

Original comment by charlie....@gmail.com on 5 Jun 2011 at 10:54