Fixed None type error message after getting the locale setting

This commit is contained in:
Oğuz Yarımtepe 2008-12-18 19:16:40 +00:00
parent 8aa18bf4cb
commit e584c1e25c
2 changed files with 19 additions and 15 deletions

View File

@ -91,7 +91,12 @@ def template_info(item, date_format):
#set the locale so that the dates at the feeds will be in english
lc=locale.getlocale()
if lc[0].find("tr") != -1:
if lc[0] == None:
try:
locale.setlocale(locale.LC_ALL, '')
except:
pass
elif lc[0].find("tr") != -1:
try:
locale.setlocale(locale.LC_ALL, '')
except:

View File

@ -107,7 +107,7 @@
<foaf:name>Alper Orus</foaf:name>
<foaf:weblog>
<foaf:Document rdf:about="http://www.murekkep.org">
<dc:title>Mürekkep - İnternet Yaşam Rehberiniz » admin</dc:title>
<dc:title>Mürekkep - İnternet Yaşam Rehberiniz » Bilişim</dc:title>
<rdfs:seeAlso>
<rss:channel rdf:about="" />
</rdfs:seeAlso>
@ -245,20 +245,19 @@
</foaf:weblog>
</foaf:Agent>
</foaf:member>
<foaf:member>
<foaf:Agent>
<foaf:name>Ceyhun Alyeşil</foaf:name>
<foaf:weblog>
<foaf:Document rdf:about="http://devador.blogspot.com">
<dc:title></dc:title>
<rdfs:seeAlso>
<rss:channel rdf:about="" />
</rdfs:seeAlso>
</foaf:Document>
</foaf:weblog>
</foaf:Agent>
</foaf:member>
<foaf:Agent>
<foaf:name>Ceyhun Alyeşil</foaf:name>
<foaf:weblog>
<foaf:Document rdf:about="">
<dc:title></dc:title>
<rdfs:seeAlso>
<rss:channel rdf:about="" />
</rdfs:seeAlso>
</foaf:Document>
</foaf:weblog>
</foaf:Agent>
</foaf:member>
<foaf:member>
<foaf:Agent>
<foaf:name>Deniz Koçak</foaf:name>