(Partial)Guild(Id)::audit_logs
takes in raw action type IDs instead of the Action
enum
#2488
Labels
(Partial)Guild(Id)::audit_logs
takes in raw action type IDs instead of the Action
enum
#2488
Currently,
serenity::model::Guild::audit_logs
(as well as the equivalent methods inGuildId
andPartialGuildId
) take anOption<u8>
for the optional action type field. This is incredibly bad for multiple reasons, such as allowing the user to easily and mistakenly specify incorrect type IDs, and requiring a comment explaining the magic number in many cases.Since Serenity already has an
Action
enum that models this action type very clearly, we should definitely refactor theaudit_log
methods to use this enum in 0.12.x.The text was updated successfully, but these errors were encountered: