Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Sep 2014 22:08:37 +0000 (UTC)
From:      John Marino <marino@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r368350 - in head/www/trac: . files
Message-ID:  <201409162208.s8GM8bi3016857@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: marino
Date: Tue Sep 16 22:08:36 2014
New Revision: 368350
URL: http://svnweb.freebsd.org/changeset/ports/368350
QAT: https://qat.redports.org/buildarchive/r368350/

Log:
  www/trac: Backport fix for upstream issue #11345
  
  PR:		187133
  Submitted by:	lorne (cons.org.nz)

Added:
  head/www/trac/files/patch-trac_util_translation.py   (contents, props changed)
Modified:
  head/www/trac/Makefile

Modified: head/www/trac/Makefile
==============================================================================
--- head/www/trac/Makefile	Tue Sep 16 21:49:12 2014	(r368349)
+++ head/www/trac/Makefile	Tue Sep 16 22:08:36 2014	(r368350)
@@ -3,7 +3,7 @@
 
 PORTNAME=	trac
 PORTVERSION=	1.0.1
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	www devel python
 MASTER_SITES=	http://ftp.edgewall.com/pub/trac/ \
 		ftp://ftp.edgewall.com/pub/trac/

Added: head/www/trac/files/patch-trac_util_translation.py
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/trac/files/patch-trac_util_translation.py	Tue Sep 16 22:08:36 2014	(r368350)
@@ -0,0 +1,32 @@
+Backported from fixes contained in http://trac.edgewall.org/ticket/11345
+
+--- trac/util/translation.py.orig
++++ trac/util/translation.py
+@@ -150,6 +150,6 @@
+                 t = self._null_translations
+             else:
+-                t.add(Translations.load(locale_dir, locale or 'en_US',
+-                                        'tracini'))
++                self._add(t, Translations.load(locale_dir, locale or 'en_US',
++                                               'tracini'))
+                 if env_path:
+                     with self._plugin_domains_lock:
+@@ -157,5 +157,6 @@
+                         domains = domains.items()
+                     for domain, dirname in domains:
+-                        t.add(Translations.load(dirname, locale, domain))
++                        self._add(t, Translations.load(dirname, locale,
++                                                       domain))
+             self._current.translations = t
+             self._activate_failed = False
+@@ -184,4 +185,10 @@
+             return self._current.translations is not None \
+                    or self._activate_failed
++
++        # Internal methods
++
++        def _add(self, t, translations):
++            if isinstance(translations, Translations):
++                t.add(translations)
+ 
+         # Delegated methods



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201409162208.s8GM8bi3016857>