Dot-Notation: x._id = ObjectId() doesn't seem to work properly
For whatever reason, this does not work as expected: entry._id = ObjectId() Need to go this way: entry['_id'] = ObjectId()
This commit is contained in:
parent
eabe6b678a
commit
3618a9ac51
@ -52,7 +52,7 @@ def submit_start(request):
|
||||
|
||||
# create entry and save in database
|
||||
entry = request.db.MediaEntry()
|
||||
entry._id = ObjectId()
|
||||
entry['_id'] = ObjectId()
|
||||
entry['title'] = (
|
||||
unicode(request.POST['title'])
|
||||
or unicode(splitext(filename)[0]))
|
||||
|
Loading…
x
Reference in New Issue
Block a user