Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Use the new code style in the events docs

NyanKiyoshid1e4d6995fee
diff --git a/docs/architecture/events.rst b/docs/architecture/events.rst
index 22e4baf22d..25e4890cef 100644
--- a/docs/architecture/events.rst
+++ b/docs/architecture/events.rst
@@ -28,8 +28,7 @@ To send an event, simply do the following:
from saleor.order import events
# returns an OrderEvent
- events.note_added_event(
- order=order, user=user, message='hello world!')
+ events.note_added_event(order=order, user=user, message="hello world!")
If now you want to send a 'sent email' event you would do the following:
@@ -38,8 +37,10 @@ If now you want to send a 'sent email' event you would do the following:
from saleor.order import events
events.email_sent_event(
- order=order, user=user,
- email_type=events.OrderEventsEmails.TRACKING_UPDATED)
+ order=order,
+ user=user,
+ email_type=events.OrderEventsEmails.TRACKING_UPDATED,
+ )
Notice how we are providing the email type.