diff options
| author | LHHDZ <changlin.shi@ly.com> | 2022-09-29 04:25:59 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-09-28 13:25:59 -0700 |
| commit | e00a12b099213515b49fbdb97544b9e5ee734e90 (patch) | |
| tree | f7516bb411d8e9531c7cf0850e40c7ae17baddbe /weed/filer | |
| parent | aacdcc4cad3d3aea58144640545a630c8b62d11a (diff) | |
| download | seaweedfs-e00a12b099213515b49fbdb97544b9e5ee734e90.tar.xz seaweedfs-e00a12b099213515b49fbdb97544b9e5ee734e90.zip | |
associate `Account` and `Identity` by accountId (#3754)
Diffstat (limited to 'weed/filer')
| -rw-r--r-- | weed/filer/s3iam_conf.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/weed/filer/s3iam_conf.go b/weed/filer/s3iam_conf.go index ce662b969..ea5b1a040 100644 --- a/weed/filer/s3iam_conf.go +++ b/weed/filer/s3iam_conf.go @@ -10,7 +10,11 @@ import ( ) func ParseS3ConfigurationFromBytes[T proto.Message](content []byte, config T) error { - if err := jsonpb.Unmarshal(content, config); err != nil { + options := &jsonpb.UnmarshalOptions{ + DiscardUnknown: true, + AllowPartial: true, + } + if err := options.Unmarshal(content, config); err != nil { return err } return nil |
