mirror of
				https://github.com/ItzCrazyKns/Perplexica.git
				synced 2025-11-03 20:28:14 +00:00 
			
		
		
		
	feat(config): remove unused vars
This commit is contained in:
		@@ -1,5 +1,4 @@
 | 
			
		||||
[GENERAL]
 | 
			
		||||
PORT = 3001 # Port to run the server on
 | 
			
		||||
SIMILARITY_MEASURE = "cosine" # "cosine" or "dot"
 | 
			
		||||
KEEP_ALIVE = "5m" # How long to keep Ollama models loaded into memory. (Instead of using -1 use "-1m")
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -6,7 +6,6 @@ const configFileName = 'config.toml';
 | 
			
		||||
 | 
			
		||||
interface Config {
 | 
			
		||||
  GENERAL: {
 | 
			
		||||
    PORT: number;
 | 
			
		||||
    SIMILARITY_MEASURE: string;
 | 
			
		||||
    KEEP_ALIVE: string;
 | 
			
		||||
  };
 | 
			
		||||
@@ -46,8 +45,6 @@ const loadConfig = () =>
 | 
			
		||||
    fs.readFileSync(path.join(process.cwd(), `${configFileName}`), 'utf-8'),
 | 
			
		||||
  ) as any as Config;
 | 
			
		||||
 | 
			
		||||
export const getPort = () => loadConfig().GENERAL.PORT;
 | 
			
		||||
 | 
			
		||||
export const getSimilarityMeasure = () =>
 | 
			
		||||
  loadConfig().GENERAL.SIMILARITY_MEASURE;
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user