Show More
@@ -99,6 +99,17 b' def urlencodenested(params):' | |||
|
99 | 99 | process('', params) |
|
100 | 100 | return util.urlreq.urlencode(flatparams) |
|
101 | 101 | |
|
102 | def readlegacytoken(repo): | |
|
103 | """Transitional support for old phabricator tokens. | |
|
104 | ||
|
105 | Remove before the 4.6 release. | |
|
106 | """ | |
|
107 | token = repo.ui.config('phabricator', 'token') | |
|
108 | if token: | |
|
109 | repo.ui.warn(_('phabricator.token is deprecated - please ' | |
|
110 | 'migrate to the phabricator.auth section.\n')) | |
|
111 | return token | |
|
112 | ||
|
102 | 113 | def readurltoken(repo): |
|
103 | 114 | """return conduit url, token and make sure they exist |
|
104 | 115 | |
@@ -128,8 +139,10 b' def readurltoken(repo):' | |||
|
128 | 139 | break |
|
129 | 140 | |
|
130 | 141 | if not token: |
|
131 | raise error.Abort(_('Can\'t find conduit token associated to %s') | |
|
132 | % (url,)) | |
|
142 | token = readlegacytoken(repo) | |
|
143 | if not token: | |
|
144 | raise error.Abort(_('Can\'t find conduit token associated to %s') | |
|
145 | % (url,)) | |
|
133 | 146 | |
|
134 | 147 | return url, token |
|
135 | 148 |
General Comments 0
You need to be logged in to leave comments.
Login now