mirror of
				https://github.com/go-gitea/gitea
				synced 2025-10-31 03:18:24 +00:00 
			
		
		
		
	Backport #30305 by wxiaoguang It doesn't change logic, it only does: 1. Rename the variable and function names 2. Use more consistent format when mentioning config section&key 3. Improve some messages Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
		| @@ -235,9 +235,7 @@ var configuredPaths = make(map[string]string) | ||||
| func checkOverlappedPath(name, path string) { | ||||
| 	// TODO: some paths shouldn't overlap (storage.xxx.path), while some could (data path is the base path for storage path) | ||||
| 	if targetName, ok := configuredPaths[path]; ok && targetName != name { | ||||
| 		msg := fmt.Sprintf("Configured path %q is used by %q and %q at the same time. The paths must be unique to prevent data loss.", path, targetName, name) | ||||
| 		log.Error("%s", msg) | ||||
| 		DeprecatedWarnings = append(DeprecatedWarnings, msg) | ||||
| 		logStartupProblem(1, log.ERROR, "Configured path %q is used by %q and %q at the same time. The paths must be unique to prevent data loss.", path, targetName, name) | ||||
| 	} | ||||
| 	configuredPaths[path] = name | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user