fix: changes (#1482)

* fix: changes

* change listquery to changequery

* fix: changes in auth

Co-authored-by: Max Peintner <max@caos.ch>
This commit is contained in:
Livio Amstutz
2021-03-29 10:32:23 +02:00
committed by GitHub
parent 0a058a821e
commit 48456b84b9
12 changed files with 54 additions and 38 deletions

View File

@@ -8,6 +8,13 @@ import (
"github.com/caos/zitadel/pkg/grpc/message"
)
func ChangeQueryToModel(query *change_pb.ChangeQuery) (sequence uint64, limit uint64, asc bool) {
if query == nil {
return 0, 0, false
}
return query.Sequence, uint64(query.Limit), query.Asc
}
func UserChangesToPb(changes []*user_model.UserChange) []*change_pb.Change {
c := make([]*change_pb.Change, len(changes))
for i, change := range changes {