mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Fixed 'datasette plugins' command, with tests - closes #802
This commit is contained in:
parent
033a1bb22c
commit
f786033a5f
6 changed files with 92 additions and 61 deletions
|
|
@ -626,9 +626,9 @@ class Datasette:
|
|||
},
|
||||
}
|
||||
|
||||
def _plugins(self, request):
|
||||
def _plugins(self, request=None, all=False):
|
||||
ps = list(get_plugins())
|
||||
if not request.args.get("all"):
|
||||
if all is False or (request is not None and request.args.get("all")):
|
||||
ps = [p for p in ps if p["name"] not in DEFAULT_PLUGINS]
|
||||
return [
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue