use 127.0.0.1 instead of localhost in local urls

This commit is contained in:
Damien Elmes 2018-10-11 15:45:55 +10:00
parent 5907629406
commit 63661713df

View file

@ -272,7 +272,7 @@ body {{ zoom: {}; {} }}
def webBundlePath(self, path): def webBundlePath(self, path):
from aqt import mw from aqt import mw
return "http://localhost:%d/_anki/%s" % (mw.mediaServer.getPort(), path) return "http://127.0.0.1:%d/_anki/%s" % (mw.mediaServer.getPort(), path)
def bundledScript(self, fname): def bundledScript(self, fname):
return '<script src="%s"></script>' % self.webBundlePath(fname) return '<script src="%s"></script>' % self.webBundlePath(fname)