mirror of
				https://github.com/THIS-IS-NOT-A-BACKUP/zspotify.git
				synced 2025-11-03 21:10:34 +00:00 
			
		
		
		
	Fixes error locating config if not run from src dir
This commit is contained in:
		
							parent
							
								
									c41fc10bc2
								
							
						
					
					
						commit
						4f91554097
					
				@ -55,7 +55,8 @@ class ZSpotify:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    @classmethod
 | 
					    @classmethod
 | 
				
			||||||
    def load_config(cls) -> None:
 | 
					    def load_config(cls) -> None:
 | 
				
			||||||
        with open(CONFIG_FILE_PATH, encoding='utf-8') as config_file:
 | 
					        app_dir = os.path.dirname(__file__)
 | 
				
			||||||
 | 
					        with open(os.path.join(app_dir, CONFIG_FILE_PATH), encoding='utf-8') as config_file:
 | 
				
			||||||
            cls.CONFIG = json.load(config_file)
 | 
					            cls.CONFIG = json.load(config_file)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @classmethod
 | 
					    @classmethod
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user