Skip to content

Commit

Permalink
error obj on exec message changed
Browse files Browse the repository at this point in the history
  • Loading branch information
osolgithub committed Mar 29, 2024
1 parent 28558e8 commit 1e01db4
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/OSOLMySQL.php
Expand Up @@ -229,9 +229,10 @@ function executePS($sql,$types="",...$bindArgsRecieved)
if($stmt->execute())// or die(sprintf("Error: %s.\n", $stmt->errno ." : ". $stmt->error)."<br /> ".$sql."<br /> types :{$types }<br /> bindArgs <pre>".print_r($bindArgs,true)."</pre>");
{
//if($site_options["debug_mode"]) echo $sql."<br />";
$stmt->close();

$resultGot = array("status"=> "success","insert_id" => $this->lastInsertId());
//$resultGot = array("status"=> "success","insert_id" => $stmt->lastInsertId(),"affectedRows" => $stmt->affectedRows());
$resultGot = array("status"=> "success","insert_id" => $stmt->insert_id,"affectedRows" => $stmt->affected_rows);
$stmt->close();

}
else //if($stmt->execute())
Expand Down Expand Up @@ -513,4 +514,4 @@ private function logQuery($query)


}//class OSOLMySQL {
?>
?>

0 comments on commit 1e01db4

Please sign in to comment.