mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-14 03:54:10 +01:00
postgres fix, auto-id column need to be NOT set
This commit is contained in:
parent
f970ef346f
commit
9ae99b8003
@ -170,6 +170,9 @@ class accounts_backend
|
|||||||
if (!isset($to_write['account_pwd'])) $to_write['account_pwd'] = ''; // is NOT NULL!
|
if (!isset($to_write['account_pwd'])) $to_write['account_pwd'] = ''; // is NOT NULL!
|
||||||
if (!isset($to_write['account_status'])) $to_write['account_status'] = ''; // is NOT NULL!
|
if (!isset($to_write['account_status'])) $to_write['account_status'] = ''; // is NOT NULL!
|
||||||
|
|
||||||
|
// postgres requires the auto-id field to be unset!
|
||||||
|
if (isset($to_write['account_id']) && !$to_write['account_id']) unset($to_write['account_id']);
|
||||||
|
|
||||||
if (!in_array($to_write['account_type'],array('u','g')) ||
|
if (!in_array($to_write['account_type'],array('u','g')) ||
|
||||||
!$this->db->insert($this->table,$to_write,false,__LINE__,__FILE__)) return false;
|
!$this->db->insert($this->table,$to_write,false,__LINE__,__FILE__)) return false;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user