mirror of
https://github.com/rclone/rclone.git
synced 2024-11-22 08:23:47 +01:00
all: Apply codeql fixes
This commit is contained in:
parent
2dabbe83ac
commit
745c0af571
@ -511,7 +511,7 @@ Example: "https://contoso.sharepoint.com/sites/mysite" or "mysite"
|
||||
`)
|
||||
case "url_end":
|
||||
siteURL := config.Result
|
||||
re := regexp.MustCompile(`https://.*\.sharepoint.com/sites/(.*)`)
|
||||
re := regexp.MustCompile(`https://.*\.sharepoint\.com/sites/(.*)`)
|
||||
match := re.FindStringSubmatch(siteURL)
|
||||
if len(match) == 2 {
|
||||
return chooseDrive(ctx, name, m, srv, chooseDriveOpt{
|
||||
|
@ -214,7 +214,7 @@ func NewFs(ctx context.Context, name string, root string, config configmap.Mappe
|
||||
|
||||
client := fshttp.NewClient(ctx)
|
||||
f.srv = rest.NewClient(client).SetRoot(apiBaseURL)
|
||||
f.IDRegexp = regexp.MustCompile("https://uptobox.com/([a-zA-Z0-9]+)")
|
||||
f.IDRegexp = regexp.MustCompile(`https://uptobox\.com/([a-zA-Z0-9]+)`)
|
||||
|
||||
_, err = f.readMetaDataForPath(ctx, f.dirPath(""), &api.MetadataRequestOptions{Limit: 10})
|
||||
if err != nil {
|
||||
|
@ -18,7 +18,7 @@ func (x *FileMode) String() string {
|
||||
|
||||
// Set a FileMode
|
||||
func (x *FileMode) Set(s string) error {
|
||||
i, err := strconv.ParseInt(s, 8, 64)
|
||||
i, err := strconv.ParseInt(s, 8, 32)
|
||||
if err != nil {
|
||||
return fmt.Errorf("bad FileMode - must be octal digits: %w", err)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user