mirror of
				https://github.com/warengroup/eximiabots-radiox.git
				synced 2025-11-04 14:09:33 +00:00 
			
		
		
		
	Catch errors inside loadEntry method in Datastore class
This commit is contained in:
		@@ -48,8 +48,11 @@ module.exports = class {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    loadEntry(id){
 | 
			
		||||
        const json = require(`../../../datastore/` + id + '.json');
 | 
			
		||||
        this.map.set(id, json);
 | 
			
		||||
        try {
 | 
			
		||||
            const json = require(`../../../datastore/` + id + '.json');
 | 
			
		||||
            this.map.set(id, json);
 | 
			
		||||
        } catch (error) {
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    getEntry(id){
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user