src/libraries/adapters/DatabaseMySql.php
/**
    * Add a new credential to the database
    * This method does not overwrite existing values present in $params - hence "new credential".
    *
    * @param string $id ID of the credential to update which is always 1.
    * @param array $params Attributes to update.
    * @return boolean
    */
Add a new credential to the database
This method does not overwrite existing values present in $params - hence "new credential".

@param string $id ID of the credential to update which is always 1.
@param array $params Attributes to update.
@return boolean
Add a new credential to the database This method does not overwrite existing values present in $params - hence " new credential " . @param string $id ID of the credential to update which is always 1 . @param array $params Attributes to update . @return boolean
public function putCredential($id, $params)
  {
    $params['owner'] = $this->owner;
    if(!isset($params['id']))
      $params['id'] = $id;
    $params = $this->prepareCredential($params);
    $stmt = $this->sqlInsertExplode($params);
    $result = $this->db->execute("INSERT INTO `{$this->mySqlTablePrefix}credential` ({$stmt['cols']}) VALUES ({$stmt['vals']})");
    return ($result !== false);
  }
public function putCredential ( $ id , $ params ) { $ params [ 'owner' ] = $ this -> owner ; if ( ! isset ( $ params [ 'id' ] ) ) $ params [ 'id' ] = $ id ; $ params = $ this -> prepareCredential ( $ params ) ; $ stmt = $ this -> sqlInsertExplode ( $ params ) ; $ result = $ this -> db -> execute ( " INSERT INTO ` { $ this -> mySqlTablePrefix } credential` ( { $ stmt [ 'cols' ] } ) VALUES ( { $ stmt [ 'vals' ] } ) " ) ; return ( $ result !== false ) ; }
Add a new credential to the database
 This method does not overwrite existing values present in $params - hence "new credential".
Add a new credential to the database This method does not overwrite existing values present in $params - hence " new credential " .