fixed a problem with keyed tables and record_id, thanks Ben Goosman

This commit is contained in:
Massimo Di Pierro
2012-01-24 08:27:17 -06:00
parent 61a3cc9461
commit f98ef25d32
4 changed files with 8 additions and 8 deletions
+1 -2
View File
@@ -3177,8 +3177,7 @@ class Crud(object):
method: Crud.delete(table, record_id, [next=DEFAULT
[, message=DEFAULT]])
"""
if not (isinstance(table, self.db.Table) or table in self.db.tables) \
or not str(record_id).isdigit():
if not (isinstance(table, self.db.Table) or table in self.db.tables):
raise HTTP(404)
if not isinstance(table, self.db.Table):
table = self.db[table]