public function get(string $key): string
    {
        if (!$this->users_id) {
            throw new Exception('No users is set to save config');
        }

        if ($config = $this->findFirst(['conditions' => 'users_id = ?0 and name = ?1', 'bind' => [$this->users_id, $key]])) {
            return $config->value;
        }

        throw new Exception('No value found for key: ' . $key);
    }
public function get(string $key): string
    {
        if (!$this->users_id) {
            throw new Exception('No users is set to save config');
        }

        if ($config = $this->findFirst(['conditions' => 'users_id = ?0 and name = ?1', 'bind' => [$this->users_id, $key]])) {
            return $config->value;
        }

        throw new Exception('No value found for key: ' . $key);
    }
public function get ( string $ key ) : string { if ( ! $ this -> users_id ) { throw new Exception ( 'No users is set to save config' ) ; } if ( $ config = $ this -> findFirst ( [ 'conditions' => 'users_id = ?0 and name = ?1' , 'bind' => [ $ this -> users_id , $ key ] ] ) ) { return $ config -> value ; } throw new Exception ( 'No value found for key: ' . $ key ) ; }
get a value to the table

@param string $key
@param string $value
get a value to the table