Skip to content
This repository has been archived by the owner on Oct 5, 2021. It is now read-only.

Commit

Permalink
post everything twice - fixed ticket #83
Browse files Browse the repository at this point in the history
  • Loading branch information
Olivier Demah committed May 4, 2015
1 parent 3c663b9 commit 46572d1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions django_th/html_entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def html_entity_decode_char(self, m, defs=htmlentities.entitydefs):
decode html entity into one of the html char
"""
try:
char = defs[m.group(1)] + ";"
char = defs[m.group(1)]
return "&{char};".format(char=char)
except KeyError:
return m.group(0)
Expand All @@ -29,7 +29,7 @@ def html_entity_decode_codepoint(self, m,
decode html entity into one of the codepoint2name
"""
try:
char = defs[m.group(1)] + ";"
char = defs[m.group(1)]
return "&{char};".format(char=char)
except KeyError:
return m.group(0)
Expand Down
6 changes: 3 additions & 3 deletions django_th/management/commands/fire_th.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# coding: utf-8
from __future__ import unicode_literals

import datetime
Expand Down Expand Up @@ -35,10 +35,10 @@ def to_datetime(self, data):
my_date_time = None

if 'published_parsed' in data:
my_date_time = datetime.datetime.fromtimestamp(
my_date_time = datetime.datetime.utcfromtimestamp(
time.mktime(data.published_parsed))
elif 'updated_parsed' in data:
my_date_time = datetime.datetime.fromtimestamp(
my_date_time = datetime.datetime.utcfromtimestamp(
time.mktime(data.updated_parsed))
elif 'my_date' in data:
my_date_time = arrow.get(str(data['my_date']),
Expand Down

0 comments on commit 46572d1

Please sign in to comment.