summaryrefslogtreecommitdiff
path: root/mobile
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2010-04-07 11:46:39 +0400
committerAndrew Dolgov <[email protected]>2010-04-07 11:46:39 +0400
commitb2a653c37f882dab30ba0e063c157413ff23ac31 (patch)
tree4d7eb1cc07384f4ba574e5ad170ef417fc2f2f9a /mobile
parent7a293008b60389f51a30b497178eb0ed70dcbaa6 (diff)
properly check for entry id array being present before iterating it in mobile/classic (closes #267)
Diffstat (limited to 'mobile')
-rw-r--r--mobile/classic/functions.php14
1 files changed, 8 insertions, 6 deletions
diff --git a/mobile/classic/functions.php b/mobile/classic/functions.php
index 05409d630..c7acba79e 100644
--- a/mobile/classic/functions.php
+++ b/mobile/classic/functions.php
@@ -364,12 +364,14 @@
}
if ($catchup_op == "selection") {
- $ids_to_mark = array_keys($_GET["sel_ids"]);
- if ($ids_to_mark) {
- foreach ($ids_to_mark as $id) {
- db_query($link, "UPDATE ttrss_user_entries SET
- unread = false,last_read = NOW()
- WHERE ref_id = '$id' AND owner_uid = " . $_SESSION["uid"]);
+ if (is_array($_GET["sel_ids"])) {
+ $ids_to_mark = array_keys($_GET["sel_ids"]);
+ if ($ids_to_mark) {
+ foreach ($ids_to_mark as $id) {
+ db_query($link, "UPDATE ttrss_user_entries SET
+ unread = false,last_read = NOW()
+ WHERE ref_id = '$id' AND owner_uid = " . $_SESSION["uid"]);
+ }
}
}
}