Skip to content

Commit

Permalink
GODRIER-2696 Use default revision for skip num
Browse files Browse the repository at this point in the history
  • Loading branch information
prestonvasquez committed May 10, 2024
1 parent c94c4e6 commit 49e44f8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 2 additions & 5 deletions mongo/gridfs_bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -197,11 +197,8 @@ func (b *GridFSBucket) OpenDownloadStreamByName(
return nil, fmt.Errorf("failed to construct arguments from options: %w", err)
}

var numSkip int32 = -1

if args.Revision == nil {
args.Revision = &options.DefaultRevision
} else {
numSkip := options.DefaultRevision
if args.Revision != nil {
numSkip = *args.Revision
}

Expand Down
2 changes: 0 additions & 2 deletions mongo/options/clientoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -517,8 +517,6 @@ func (c *ClientOptions) GetURI() string {
// error found.
func (c *ClientOptions) Validate() error {
args, err := getArgs[ClientArgs](c)
//return err

if err != nil {
return err
}
Expand Down

0 comments on commit 49e44f8

Please sign in to comment.