Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
plugin_dbui
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
w2pext
plugin_dbui
Commits
a703be42
Commit
a703be42
authored
13 years ago
by
Renaud Le Gac
Browse files
Options
Downloads
Patches
Plain Diff
Polish the function get_plugin_path: return None when the plugin is not found.
parent
e4423172
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/plugin_dbui/helper.py
+2
-2
2 additions, 2 deletions
modules/plugin_dbui/helper.py
with
2 additions
and
2 deletions
modules/plugin_dbui/helper.py
+
2
−
2
View file @
a703be42
...
@@ -64,7 +64,7 @@ def get_plugin_path(environment, plugin_name):
...
@@ -64,7 +64,7 @@ def get_plugin_path(environment, plugin_name):
The dictionary environment contains the keys request, response,
The dictionary environment contains the keys request, response,
session, plugins, ....
session, plugins, ....
R
aise the exception HTTP(500)
if the plugin is not found.
R
eturn None
if the plugin is not found.
"""
"""
server_path
,
client_path
=
get_reference_paths
(
environment
)
server_path
,
client_path
=
get_reference_paths
(
environment
)
...
@@ -77,7 +77,7 @@ def get_plugin_path(environment, plugin_name):
...
@@ -77,7 +77,7 @@ def get_plugin_path(environment, plugin_name):
return
os
.
path
.
join
(
client_path
,
'
static
'
,
el
)
return
os
.
path
.
join
(
client_path
,
'
static
'
,
el
)
# Nothing found
# Nothing found
r
aise
HTTP
(
500
,
'
The plugin %s is not install !
'
%
plugin_name
)
r
eturn
None
def
get_js_files
(
server_path
,
client_path
,
directory
):
def
get_js_files
(
server_path
,
client_path
,
directory
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment