mirror of
				https://github.com/songquanpeng/one-api.git
				synced 2025-11-04 07:43:41 +08:00 
			
		
		
		
	chore: move config key to package ctxkey
This commit is contained in:
		@@ -1,13 +0,0 @@
 | 
			
		||||
package config
 | 
			
		||||
 | 
			
		||||
const (
 | 
			
		||||
	KeyPrefix = "cfg_"
 | 
			
		||||
 | 
			
		||||
	KeyAPIVersion = KeyPrefix + "api_version"
 | 
			
		||||
	KeyLibraryID  = KeyPrefix + "library_id"
 | 
			
		||||
	KeyPlugin     = KeyPrefix + "plugin"
 | 
			
		||||
	KeySK         = KeyPrefix + "sk"
 | 
			
		||||
	KeyAK         = KeyPrefix + "ak"
 | 
			
		||||
	KeyRegion     = KeyPrefix + "region"
 | 
			
		||||
	KeyUserID     = KeyPrefix + "user_id"
 | 
			
		||||
)
 | 
			
		||||
							
								
								
									
										13
									
								
								common/ctxkey/config.go
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								common/ctxkey/config.go
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,13 @@
 | 
			
		||||
package ctxkey
 | 
			
		||||
 | 
			
		||||
const (
 | 
			
		||||
	ConfigPrefix = "cfg_"
 | 
			
		||||
 | 
			
		||||
	ConfigAPIVersion = ConfigPrefix + "api_version"
 | 
			
		||||
	ConfigLibraryID  = ConfigPrefix + "library_id"
 | 
			
		||||
	ConfigPlugin     = ConfigPrefix + "plugin"
 | 
			
		||||
	ConfigSK         = ConfigPrefix + "sk"
 | 
			
		||||
	ConfigAK         = ConfigPrefix + "ak"
 | 
			
		||||
	ConfigRegion     = ConfigPrefix + "region"
 | 
			
		||||
	ConfigUserID     = ConfigPrefix + "user_id"
 | 
			
		||||
)
 | 
			
		||||
		Reference in New Issue
	
	Block a user