mirror of
https://github.com/linuxserver/core.git
synced 2026-02-20 05:07:19 +08:00
Merge remote-tracking branch 'origin/pull/c9.ide.language.python/4'
This commit is contained in:
commit
fd518a3e14
@ -50,11 +50,12 @@ class Daemon(BaseHTTPRequestHandler):
|
||||
def to_json(mode, nodoc):
|
||||
include_pos = mode == "goto_definitions"
|
||||
def to_json(c):
|
||||
try:
|
||||
paramList = { p.description for p in c.params }
|
||||
params = ", ".join([p for p in paramList if p != None and p != "self"])
|
||||
except:
|
||||
params = ""
|
||||
if c.type == "function":
|
||||
try:
|
||||
paramList = { p.description for p in c.params }
|
||||
params = ", ".join([p for p in paramList if p != None and p != "self"])
|
||||
except:
|
||||
params = ""
|
||||
return remove_nulls({
|
||||
"name": c.name + ("(" + params + ")" if c.type == "function" else ""),
|
||||
"replaceText": c.name + "(^^)" if c.type == "function" else None,
|
||||
@ -95,4 +96,4 @@ if __name__ == "__main__":
|
||||
parser.add_argument("--port", type=int, help="The port for the daemon to listen on")
|
||||
parser.add_argument("--nodoc", help="Don't include docstrings in output")
|
||||
args = parser.parse_args()
|
||||
main(args)
|
||||
main(args)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user