1
0
mirror of https://github.com/mattermost/focalboard.git synced 2025-07-09 23:45:41 +02:00
Files
focalboard/server/model/sharing.go

21 lines
389 B
Go
Raw Normal View History

2021-01-12 15:35:30 -08:00
package model
2021-01-12 16:44:50 -08:00
import (
"encoding/json"
"io"
)
2021-01-12 15:35:30 -08:00
type Sharing struct {
ID string `json:"id"`
Enabled bool `json:"enabled"`
2021-01-12 16:52:25 -08:00
Token string `json:"token"`
2021-01-12 15:35:30 -08:00
ModifiedBy string `json:"modifiedBy"`
UpdateAt int64 `json:"update_at,omitempty"`
}
2021-01-12 16:44:50 -08:00
func SharingFromJSON(data io.Reader) Sharing {
var sharing Sharing
json.NewDecoder(data).Decode(&sharing)
return sharing
}