0

I've attached a handler to the django.contrib.comments signals (comment_was_posted and comment_will_be_posted). Each handler is being called twice. I can't seem to figure out why, nor can I figure out how to tell if I'm on the first or second call. I only want to run the code once. Any feedback would be much appreciated.

dubloons
  • 1,136
  • 2
  • 12
  • 25

1 Answers1

0

Signals firing twice is usually the result of the registration code firing twice.

https://docs.djangoproject.com/en/dev/topics/signals/#preventing-duplicate-signals

dubloons
  • 1,136
  • 2
  • 12
  • 25