mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
webcommands: move help import into help command handler
A subsequent patch will introduce an import cycle between mercurial.help and mercurial.hgweb.webcommands. Break the cycle by moving the import of mercurial.help into the web command that actually needs it.
This commit is contained in:
parent
11ed5adff7
commit
4498c4489d
@ -13,7 +13,6 @@ from mercurial import util
|
||||
from common import paritygen, staticfile, get_contact, ErrorResponse
|
||||
from common import HTTP_OK, HTTP_FORBIDDEN, HTTP_NOT_FOUND
|
||||
from mercurial import graphmod, patch
|
||||
from mercurial import help as helpmod
|
||||
from mercurial import scmutil
|
||||
from mercurial.i18n import _
|
||||
from mercurial.error import ParseError, RepoLookupError, Abort
|
||||
@ -1083,6 +1082,7 @@ def _getdoc(e):
|
||||
@webcommand('help')
|
||||
def help(web, req, tmpl):
|
||||
from mercurial import commands # avoid cycle
|
||||
from mercurial import help as helpmod # avoid cycle
|
||||
|
||||
topicname = req.form.get('node', [None])[0]
|
||||
if not topicname:
|
||||
|
Loading…
Reference in New Issue
Block a user