Skip to content

Commit 5d9c07e

Browse files
committed
logline for debugging
1 parent 4a85e52 commit 5d9c07e

File tree

3 files changed

+22
-22
lines changed

3 files changed

+22
-22
lines changed

go.mod

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@ require (
3232
github.com/ReneKroon/ttlcache/v2 v2.11.0 // indirect
3333
github.com/cern-eos/go-eosgrpc v0.0.0-20240909164147-ad693be93181 // indirect
3434
github.com/creasty/defaults v1.8.0 // indirect
35-
github.com/gabriel-vasile/mimetype v1.4.7 // indirect
35+
github.com/gabriel-vasile/mimetype v1.4.8 // indirect
3636
github.com/glpatcern/go-mime v0.0.0-20221026162842-2a8d71ad17a9 // indirect
3737
github.com/go-asn1-ber/asn1-ber v1.5.7 // indirect
38-
github.com/go-ldap/ldap/v3 v3.4.9 // indirect
38+
github.com/go-ldap/ldap/v3 v3.4.10 // indirect
3939
github.com/go-playground/locales v0.14.1 // indirect
4040
github.com/go-playground/universal-translator v0.18.1 // indirect
41-
github.com/go-playground/validator/v10 v10.23.0 // indirect
41+
github.com/go-playground/validator/v10 v10.25.0 // indirect
4242
github.com/gofrs/uuid v4.4.0+incompatible // indirect
4343
github.com/golang-jwt/jwt v3.2.2+incompatible // indirect
4444
github.com/golang/protobuf v1.5.4 // indirect

go.sum

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c
3131
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
3232
github.com/disintegration/imaging v1.6.2 h1:w1LecBlG2Lnp8B3jk5zSuNqd7b4DXhcjwek1ei82L+c=
3333
github.com/disintegration/imaging v1.6.2/go.mod h1:44/5580QXChDfwIclfc/PCwrr44amcmDAg8hxG0Ewe4=
34-
github.com/gabriel-vasile/mimetype v1.4.7 h1:SKFKl7kD0RiPdbht0s7hFtjl489WcQ1VyPW8ZzUMYCA=
35-
github.com/gabriel-vasile/mimetype v1.4.7/go.mod h1:GDlAgAyIRT27BhFl53XNAFtfjzOkLaF35JdEG0P7LtU=
34+
github.com/gabriel-vasile/mimetype v1.4.8 h1:FfZ3gj38NjllZIeJAmMhr+qKL8Wu+nOoI3GqacKw1NM=
35+
github.com/gabriel-vasile/mimetype v1.4.8/go.mod h1:ByKUIKGjh1ODkGM1asKUbQZOLGrPjydw3hYPU2YU9t8=
3636
github.com/gdexlab/go-render v1.0.1 h1:rxqB3vo5s4n1kF0ySmoNeSPRYkEsyHgln4jFIQY7v0U=
3737
github.com/gdexlab/go-render v1.0.1/go.mod h1:wRi5nW2qfjiGj4mPukH4UV0IknS1cHD4VgFTmJX5JzM=
3838
github.com/glpatcern/go-mime v0.0.0-20221026162842-2a8d71ad17a9 h1:3um08ooi0/lyRmK2eE1XTKmRQHDzPu0IvpCPMljyMZ8=
@@ -41,8 +41,8 @@ github.com/go-asn1-ber/asn1-ber v1.5.7 h1:DTX+lbVTWaTw1hQ+PbZPlnDZPEIs0SS/GCZAl5
4141
github.com/go-asn1-ber/asn1-ber v1.5.7/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
4242
github.com/go-chi/chi/v5 v5.2.0 h1:Aj1EtB0qR2Rdo2dG4O94RIU35w2lvQSj6BRA4+qwFL0=
4343
github.com/go-chi/chi/v5 v5.2.0/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
44-
github.com/go-ldap/ldap/v3 v3.4.9 h1:KxX9eO44/MpqPXVVMPJDB+k/35GEePHE/Jfvl7oRMUo=
45-
github.com/go-ldap/ldap/v3 v3.4.9/go.mod h1:+CE/4PPOOdEPGTi2B7qXKQOq+pNBvXZtlBNcVZY0AWI=
44+
github.com/go-ldap/ldap/v3 v3.4.10 h1:ot/iwPOhfpNVgB1o+AVXljizWZ9JTp7YF5oeyONmcJU=
45+
github.com/go-ldap/ldap/v3 v3.4.10/go.mod h1:JXh4Uxgi40P6E9rdsYqpUtbW46D9UTjJ9QSwGRznplY=
4646
github.com/go-logr/logr v1.4.2 h1:6pFjapn8bFcIbiKo3XT4j/BhANplGihG6tvd+8rYgrY=
4747
github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
4848
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
@@ -53,8 +53,8 @@ github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/o
5353
github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY=
5454
github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY=
5555
github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY=
56-
github.com/go-playground/validator/v10 v10.23.0 h1:/PwmTwZhS0dPkav3cdK9kV1FsAmrL8sThn8IHr/sO+o=
57-
github.com/go-playground/validator/v10 v10.23.0/go.mod h1:dbuPbCMFw/DrkbEynArYaCwl3amGuJotoKCe95atGMM=
56+
github.com/go-playground/validator/v10 v10.25.0 h1:5Dh7cjvzR7BRZadnsVOzPhWsrwUr0nmsZJxEAnFLNO8=
57+
github.com/go-playground/validator/v10 v10.25.0/go.mod h1:GGzBIJMuE98Ic/kJsBXbz1x/7cByt++cQ+YOuDM5wus=
5858
github.com/go-sql-driver/mysql v1.7.0/go.mod h1:OXbVy3sEdcQ2Doequ6Z5BW6fXNQTmx+9S1MCJN5yJMI=
5959
github.com/go-sql-driver/mysql v1.8.1 h1:LedoTUt/eveggdHS9qUFC1EFSa8bU2+1pZjSRpvNJ1Y=
6060
github.com/go-sql-driver/mysql v1.8.1/go.mod h1:wEBSXgmK//2ZFJyE+qWnIsVGmvmEKlqwuVSjsCm7DZg=
@@ -182,7 +182,6 @@ golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58
182182
golang.org/x/crypto v0.13.0/go.mod h1:y6Z2r+Rw4iayiXXAIxJIDAJ1zMW4yaTpebo8fPOliYc=
183183
golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU=
184184
golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8=
185-
golang.org/x/crypto v0.30.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk=
186185
golang.org/x/crypto v0.31.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk=
187186
golang.org/x/crypto v0.32.0 h1:euUpcYgM8WcP71gNpTqQCn6rC2t6ULUPiOzfWaXVVfc=
188187
golang.org/x/crypto v0.32.0/go.mod h1:ZnnJkOaASj8g0AjIduWNlq2NRxL0PlBrbKVyZ6V/Ugc=
@@ -212,7 +211,7 @@ golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
212211
golang.org/x/net v0.15.0/go.mod h1:idbUs1IY1+zTqbi8yxTbhexhEEk5ur9LInksu6HrEpk=
213212
golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44=
214213
golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM=
215-
golang.org/x/net v0.32.0/go.mod h1:CwU0IoeOlnQQWJ6ioyFrfRuomB8GKF6KbYXZVyeXNfs=
214+
golang.org/x/net v0.33.0/go.mod h1:HXLR5J+9DxmrqMwG9qjGCxZ+zKXxBru04zlTvWlWuN4=
216215
golang.org/x/net v0.34.0 h1:Mb7Mrk043xzHgnRM88suvJFwzVrRfHEHJEl5/71CKw0=
217216
golang.org/x/net v0.34.0/go.mod h1:di0qlW3YNM5oh6GqDGQr92MyTozJPmybPK4Ev/Gm31k=
218217
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=

share/sql/migrate.go

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ type OldShareEntry struct {
3939
ItemType string
4040
ShareWith string
4141
Token string
42-
Expiration string
42+
Expiration datatypes.NullTime
4343
Permissions int
4444
ShareType int
4545
ShareName string
@@ -247,7 +247,7 @@ func handleSingleState(ctx context.Context, migrator Migrator, s *OldShareState)
247247
}
248248

249249
func oldShareToNewShare(ctx context.Context, migrator Migrator, s *OldShareEntry) (*ShareOrLink, error) {
250-
expirationDate, expirationError := time.Parse("2006-01-02 15:04:05", s.Expiration)
250+
//expirationDate, expirationError := time.Parse("2006-01-02 15:04:05", s.Expiration)
251251

252252
protoShare := model.ProtoShare{
253253
Model: gorm.Model{
@@ -259,14 +259,11 @@ func oldShareToNewShare(ctx context.Context, migrator Migrator, s *OldShareEntry
259259
UIDInitiator: s.UIDInitiator,
260260
Permissions: uint8(s.Permissions),
261261
Orphan: s.Orphan, // will be re-checked later
262-
Expiration: datatypes.Null[time.Time]{
263-
V: expirationDate,
264-
Valid: expirationError == nil,
265-
},
266-
ItemType: model.ItemType(s.ItemType),
267-
InitialPath: "", // set later
268-
Inode: s.ItemSource,
269-
Instance: s.Prefix,
262+
Expiration: s.Expiration,
263+
ItemType: model.ItemType(s.ItemType),
264+
InitialPath: "", // set later
265+
Inode: s.ItemSource,
266+
Instance: s.Prefix,
270267
}
271268

272269
// Getting InitialPath
@@ -282,7 +279,7 @@ func oldShareToNewShare(ctx context.Context, migrator Migrator, s *OldShareEntry
282279
protoShare.Orphan = true
283280
} else {
284281
// We do not set, because of a general error
285-
fmt.Printf("An error occured for share %d while statting (%s, %s): %s\n", s.ID, protoShare.Instance, protoShare.Inode, err.Error())
282+
// fmt.Printf("An error occured for share %d while statting (%s, %s): %s\n", s.ID, protoShare.Instance, protoShare.Inode, err.Error())
286283
}
287284
}
288285

@@ -291,6 +288,9 @@ func oldShareToNewShare(ctx context.Context, migrator Migrator, s *OldShareEntry
291288
// ShareTypePublicLink = 3
292289
// ShareTypeFederatedCloudShare = 6
293290
// ShareTypeSpaceMembership = 7
291+
if s.NotifyUploadsExtraRecipients != "" || s.ID == 832549 {
292+
fmt.Printf("Broken-struct: %+v\n", s)
293+
}
294294
if s.ShareType == 0 || s.ShareType == 1 {
295295
return &ShareOrLink{
296296
IsShare: true,
@@ -302,6 +302,7 @@ func oldShareToNewShare(ctx context.Context, migrator Migrator, s *OldShareEntry
302302
},
303303
}, nil
304304
} else if s.ShareType == 3 {
305+
305306
return &ShareOrLink{
306307
IsShare: false,
307308
Link: &model.PublicLink{

0 commit comments

Comments
 (0)