mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
request.args.getlist() returns [] if missing, refs #774
Also added some unit tests for request.args
This commit is contained in:
parent
7ccd55a163
commit
84616a2364
4 changed files with 14 additions and 4 deletions
|
|
@ -761,9 +761,9 @@ class RequestParameters(dict):
|
|||
except (KeyError, TypeError):
|
||||
return default
|
||||
|
||||
def getlist(self, name, default=None):
|
||||
def getlist(self, name):
|
||||
"Return full list"
|
||||
return super().get(name, default)
|
||||
return super().get(name) or []
|
||||
|
||||
|
||||
class ConnectionProblem(Exception):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue