mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Fixed /-/plugins?all=1, refs #802
This commit is contained in:
parent
f786033a5f
commit
75c143a84c
3 changed files with 14 additions and 11 deletions
|
|
@ -628,7 +628,12 @@ class Datasette:
|
|||
|
||||
def _plugins(self, request=None, all=False):
|
||||
ps = list(get_plugins())
|
||||
if all is False or (request is not None and request.args.get("all")):
|
||||
should_show_all = False
|
||||
if request is not None:
|
||||
should_show_all = request.args.get("all")
|
||||
else:
|
||||
should_show_all = all
|
||||
if not should_show_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