MCPcopy Index your code
hub / github.com/diffgram/diffgram / new

Method new

shared/database/notifications/notification_user.py:23–38  ·  view source on GitHub ↗
(session=None,
            add_to_session=False,
            flush_session=False,
            notification_id=None,
            user_id=None,
            is_read=False)

Source from the content-addressed store, hash-verified

21
22 @staticmethod
23 def new(session=None,
24 add_to_session=False,
25 flush_session=False,
26 notification_id=None,
27 user_id=None,
28 is_read=False):
29
30 notification = NotificationUser(
31 notification_id=notification_id,
32 user_id=user_id,
33 is_read=is_read)
34 if add_to_session:
35 session.add(notification)
36 if flush_session:
37 session.flush()
38 return notification
39
40 @staticmethod
41 def get_by_id(session, notification_id=None, user_id=None):

Callers

nothing calls this directly

Calls 2

NotificationUserClass · 0.85
addMethod · 0.45

Tested by

no test coverage detected