Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit af9fe9a

Browse files
author
kaysen
committed
FIX: update and delete
1 parent 1e3869a commit af9fe9a

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

‎class.MySQL.php

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,13 @@ public function delete($table, $where='', $limit='', $like=false, $wheretypes=ar
261261
$query .= ' LIMIT ' . $limit;
262262
}
263263

264-
return $this->executeSQL($query);
264+
$result = $this->executeSQL($query);
265+
266+
if((int) @mysql_affected_rows($this->databaseLink) == 0){
267+
return false;
268+
}
269+
270+
return $result;
265271
}
266272

267273

@@ -344,7 +350,13 @@ public function update($table, $set, $where, $exclude = '', $datatypes=array(),
344350

345351
$query = substr($query, 0, -5);
346352

347-
return $this->executeSQL($query);
353+
$result = $this->executeSQL($query);
354+
355+
if((int) @mysql_affected_rows($this->databaseLink) == 0){
356+
return false;
357+
}
358+
359+
return $result;
348360
}
349361

350362
// 'Arrays' a single result

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /