1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-01 12:34:28 +00:00
Commit graph

5 commits

Author SHA1 Message Date
diamondburned efde3f4ea6
state, handler: Refactor state storage and sync handlers
This commit refactors a lot of packages.

It refactors the handler package, removing the Synchronous field and
replacing it the AddSyncHandler API, which allows each handler to
control whether or not it should be ran synchronously independent of
other handlers. This is useful for libraries that need to guarantee the
incoming order of events.

It also refactors the store interfaces to accept more interfaces. This
is to make the API more consistent as well as reducing potential useless
copies. The public-facing state API should still be the same, so this
change will mostly concern users with their own store implementations.

Several miscellaneous functions (such as a few in package gateway) were
modified to be more suitable to other packages, but those functions
should rarely ever be used, anyway.

Several tests are also fixed within this commit, namely fixing state's
intents bug.
2021-11-03 15:16:02 -07:00
Samuel Hernandez 40e1a3757d *: Migrated Go Modules to v3 2021-06-01 19:59:01 -07:00
diamondburned 9b4b707070 Handler: Use a free list over a linked list 2020-10-28 23:55:39 -07:00
diamondburned 75df94d9f4 *: Migrated Go Modules to v2 2020-10-28 15:39:59 -07:00
mavolin ba4b224168 handler: move package from /handler to /utils/handler 2020-07-29 16:58:33 -07:00
Renamed from handler/handler_test.go (Browse further)