following and unfollowing

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2022-05-15 11:08:36 -07:00
parent 8da251dc88
commit 7554a87d88
10 changed files with 277 additions and 15 deletions

View File

@@ -109,6 +109,30 @@ extension Notification.Name {
}
}
extension Notification.Name {
static var follow: Notification.Name {
return Notification.Name("follow")
}
}
extension Notification.Name {
static var unfollow: Notification.Name {
return Notification.Name("unfollow")
}
}
extension Notification.Name {
static var followed: Notification.Name {
return Notification.Name("followed")
}
}
extension Notification.Name {
static var unfollowed: Notification.Name {
return Notification.Name("unfollowed")
}
}
func handle_notify(_ name: Notification.Name) -> NotificationCenter.Publisher {
return NotificationCenter.default.publisher(for: name)
}