This is always called from celery right (and is there an index on log_id)?  If both are true, then I think it's worth it to leave as is (seems like a relatively small overhead to ensure that we don't bill the same sms twice).