Skip to content

Commit

Permalink
enable tracking
Browse files Browse the repository at this point in the history
  • Loading branch information
gotlium committed May 1, 2015
1 parent 71e9a30 commit e7150b5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions dbmail/backends/mail.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ def _get_message(self):

def _get_msg_with_track(self):
message = self._message
if defaults.TRACK_ENABLE is False:
return message
if ENABLE_LOGGING and self._template.enable_log:
try:
domain = Site.objects.get_current().domain
Expand Down
2 changes: 1 addition & 1 deletion dbmail/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def get_settings(key, default):
SIGNAL_DB_DEFERRED_PURGE = get_settings(
'DB_MAILER_SIGNAL_DB_DEFERRED_PURGE', True)

TRACK_ENABLE = get_settings('DB_MAILER_TRACK_ENABLE', False)
TRACK_ENABLE = get_settings('DB_MAILER_TRACK_ENABLE', True)
TRACK_PIXEL = get_settings(
'DB_MAILER_TRACK_PIXEL',
[
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.rst
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ App settings
# If tracking is enabled, Logging must be enabled to.
# DbMail urls must be configured.
# Site framework must configured and installed.
DB_MAILER_TRACK_ENABLE = False
DB_MAILER_TRACK_ENABLE = True
# Tracking image content and mime type
DB_MAILER_TRACK_PIXEL = [
Expand Down

0 comments on commit e7150b5

Please sign in to comment.