original_string: private function _insert(string $id_option, array $cfg): int
    {
      $json = ($tmp = $this->get_cfg(false, $cfg)) ? json_encode($tmp) : NULL;
      return $this->db->insert($this->class_cfg['table'], [
        $this->fields['id_option'] => $id_option,
        $this->fields['num'] => $cfg[$this->fields['num']] ?? NULL,
        $this->fields['text'] => $cfg[$this->fields['text']] ?? NULL,
        $this->fields['id_link'] => $cfg[$this->fields['id_link']] ?? NULL,
        $this->fields['id_alias'] => $cfg[$this->fields['id_alias']] ?? NULL,
        $this->fields['id_user'] => $this->id_user,
        $this->fields['cfg'] => $json
      ]);
    }
code: private function _insert(string $id_option, array $cfg): int
    {
      $json = ($tmp = $this->get_cfg(false, $cfg)) ? json_encode($tmp) : NULL;
      return $this->db->insert($this->class_cfg['table'], [
        $this->fields['id_option'] => $id_option,
        $this->fields['num'] => $cfg[$this->fields['num']] ?? NULL,
        $this->fields['text'] => $cfg[$this->fields['text']] ?? NULL,
        $this->fields['id_link'] => $cfg[$this->fields['id_link']] ?? NULL,
        $this->fields['id_alias'] => $cfg[$this->fields['id_alias']] ?? NULL,
        $this->fields['id_user'] => $this->id_user,
        $this->fields['cfg'] => $json
      ]);
    }
code_tokens: private function _insert ( string $ id_option , array $ cfg ) : int { $ json = ( $ tmp = $ this -> get_cfg ( false , $ cfg ) ) ? json_encode ( $ tmp ) : NULL ; return $ this -> db -> insert ( $ this -> class_cfg [ 'table' ] , [ $ this -> fields [ 'id_option' ] => $ id_option , $ this -> fields [ 'num' ] => $ cfg [ $ this -> fields [ 'num' ] ] ?? NULL , $ this -> fields [ 'text' ] => $ cfg [ $ this -> fields [ 'text' ] ] ?? NULL , $ this -> fields [ 'id_link' ] => $ cfg [ $ this -> fields [ 'id_link' ] ] ?? NULL , $ this -> fields [ 'id_alias' ] => $ cfg [ $ this -> fields [ 'id_alias' ] ] ?? NULL , $ this -> fields [ 'id_user' ] => $ this -> id_user , $ this -> fields [ 'cfg' ] => $ json ] ) ; }
docstring: Actually inserts a row into the preferences table
  
  @param string $id_option
  @param array $cfg
  @return int
docstring_tokens: Actually inserts a row into the preferences table