mirror of
https://github.com/wassname/simpeg.git
synced 2026-07-24 13:20:06 +08:00
Migrated % string formating
This commit is contained in:
+1
-1
@@ -266,7 +266,7 @@ def _supress_nonlocal_image_warn(self, msg, node):
|
||||
from docutils.utils import get_source_line
|
||||
|
||||
if not msg.startswith('nonlocal image URI found:'):
|
||||
self._warnfunc(msg, '%s:%s' % get_source_line(node))
|
||||
self._warnfunc(msg, '{0!s}:{1!s}'.format(*get_source_line(node)))
|
||||
|
||||
supress_nonlocal_image_warn()
|
||||
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ class Images(webapp2.RequestHandler):
|
||||
class Redirect(webapp2.RequestHandler):
|
||||
def get(self):
|
||||
path = str(self.request.path).split(os.path.sep)[3:]
|
||||
self.redirect(('/%s'%os.path.sep.join(path)), permanent=True)
|
||||
self.redirect(('/{0!s}'.format(os.path.sep.join(path))), permanent=True)
|
||||
|
||||
|
||||
class MainPage(webapp2.RequestHandler):
|
||||
|
||||
Reference in New Issue
Block a user