X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=DataObjects%2FCore_person.php;h=f2f2982c618e60443638744c8d926a0a031e4633;hb=59171aab7dcdb554ab334e2a07a1c34875439326;hp=95beb5a5405975a2e6ad3395c4e21d620f4669b7;hpb=cfd6af2b45b4112d6646590b79a18040b9f02df5;p=Pman.Core diff --git a/DataObjects/Core_person.php b/DataObjects/Core_person.php index 95beb5a5..f2f2982c 100644 --- a/DataObjects/Core_person.php +++ b/DataObjects/Core_person.php @@ -672,15 +672,14 @@ class Pman_Core_DataObjects_Core_person extends DB_DataObject $aur['passwd'] = ''; $aur['dailykey'] = ''; $aur['oath_key'] = ''; - $aur['require_oath'] = 1; + $aur['oath_key_enable'] = !empty($this->oath_key); + $aur['require_oath'] = 1; $s = DB_DataObject::Factory('core_setting'); $oath_require = $s->lookup('core', 'two_factor_authentication_requirement'); - if(!empty($oath_require) || $oath_require == 0) { - - $aur['require_oath'] = 1; - } + + // $aur['require_oath'] = !empty($oath_require) || $oath_require->val == 0 ? 0 : 1; return $aur; }