Files
ihrm/notifications/utils.py
Ashwanth Balakrishnan 58be33a8d7 Added Pre-Commit Hooks (#175)
* Added pre commit hook

* Run pre commit hook on all files

---------

Co-authored-by: Horilla <131998600+horilla-opensource@users.noreply.github.com>
2024-05-07 12:23:36 +05:30

16 lines
267 B
Python

"""' Django notifications utils file """
# -*- coding: utf-8 -*-
import sys
if sys.version > "3":
long = int # pylint: disable=invalid-name
def slug2id(slug):
return long(slug) - 110909
def id2slug(notification_id):
return notification_id + 110909