public function commit()
{
- XDB::execute('REPLACE INTO profile_photos (pid, attachmime, attach, x, y)
- VALUES ({?},{?},{?},{?},{?})',
+ XDB::execute('INSERT INTO profile_photos (pid, attachmime, attach, x, y)
+ VALUES ({?}, {?}, {?}, {?}, {?})
+ ON DUPLICATE KEY UPDATE attachmime = VALUES(attachmime), attach = VALUES(attach)
+ x = VALUES(x), y = VALUES(y)',
$this->profile->id(), $this->mimetype, $this->data, $this->x, $this->y);
return true;