Example #1
0
 /**
  * Update the extra data for a user.
  * @param  string          $username The use we wish to update.
  * @param  array           $data     The associative array containing data we want to update.
  * @throws ServerException
  * @return boolean
  */
 public function updateUserData($username, array $data)
 {
     try {
         $this->_toolbox->getUserHandler()->updateUser($username, null, null, $data);
         return true;
     } catch (\Exception $e) {
         $normalised = $this->_toolbox->normaliseDriverExceptions($e);
         throw new ServerException($normalised['message'], $normalised['code']);
     }
 }
Example #2
0
 /**
  * @covers Paradox\Toolbox::getUserHandler
  */
 public function testGetUserHandler()
 {
     $userHandler = $this->toolbox->getUserHandler();
     $this->assertInstanceOf('triagens\\ArangoDb\\UserHandler', $userHandler, 'getUserHandler() did not return a triagens\\ArangoDb\\UserHandler');
 }