mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-02 11:20:18 +08:00
feat: add all other missing objects to init_data (#1407)
* Add all other missing objects to init_data.json * Format golang code * feat: add all other missing objects to init_data * feat: add all other missing objects to init_data
This commit is contained in:
@ -169,6 +169,10 @@ func GetToken(id string) *Token {
|
||||
return getToken(owner, name)
|
||||
}
|
||||
|
||||
func (token *Token) GetId() string {
|
||||
return fmt.Sprintf("%s/%s", token.Owner, token.Name)
|
||||
}
|
||||
|
||||
func UpdateToken(id string, token *Token) bool {
|
||||
owner, name := util.GetOwnerAndNameFromId(id)
|
||||
if getToken(owner, name) == nil {
|
||||
|
Reference in New Issue
Block a user