1. pombredanne
  2. cmsplugin-markup-tracwiki

Commits

mitar  committed a540b02

Making code more robust.

  • Participants
  • Parent commits 206c8bb
  • Branches default

Comments (0)

Files changed (1)

File cmsplugin_markup_tracwiki/tracwiki.py

View file
  • Ignore whitespace
     def set_abs_href(self, request):
         site = sites_models.Site.objects.get_current() if sites_models.Site._meta.installed else sites_models.RequestSite(request)
 
-        server_port = request.META.get('SERVER_PORT', '80')
+        server_port = str(request.META.get('SERVER_PORT', '80'))
         if request.is_secure():
             self.abs_href = web.href.Href('https://' + site.domain + (':' + server_port if server_port != '443' else '') + self.href())
         else: