Mercurial > hg > fapweb
changeset 681:bf8a5009b3f2
Add some error cases.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sun, 09 Nov 2014 14:46:48 +0200 |
parents | c9b96a7b9dc4 |
children | 2e54b6858ce9 |
files | admajax.php |
diffstat | 1 files changed, 6 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/admajax.php Sun Nov 09 14:17:34 2014 +0200 +++ b/admajax.php Sun Nov 09 14:46:48 2014 +0200 @@ -1091,6 +1091,8 @@ $res = stFetchSQL(stPrepareSQL("SELECT * FROM attendees WHERE id=%D", "id")); if ($res !== FALSE) stPrintAttendee($res, -1, FALSE, TRUE, stGetRequestItem("edit", FALSE)); + else + stError("No such attendee ID!"); break; case "votekey": @@ -1221,6 +1223,8 @@ $res = stFetchSQL(stPrepareSQL("SELECT * FROM compos WHERE id=%D", "id")); if ($res !== FALSE) echo stGetCompoData($res["id"], $res, "co"); + else + stError("No such compo ID!"); break; case "settingslist": @@ -1350,6 +1354,8 @@ $res = stFetchSQL(stPrepareSQL("SELECT * FROM entries WHERE id=%D", "id")); if ($res !== FALSE) echo stGetEntryItemData($res["id"], $res, "en"); + else + stError("No such entry ID!"); break; } break;