mirror of
https://github.com/diamondburned/arikawa.git
synced 2024-11-19 21:32:49 +00:00
12 lines
435 B
Go
12 lines
435 B
Go
// Package discord provides common structures that the whole repository uses. It
|
|
// does not (and should not) contain API-specific structures, or WS-specific
|
|
// structures.
|
|
package discord
|
|
|
|
// HasFlag is returns true if has is in the flag. In other words, it checks if
|
|
// has is OR'ed into flag. This function could be used for different constants
|
|
// such as Permission.
|
|
func HasFlag(flag, has uint64) bool {
|
|
return flag&has == has
|
|
}
|