mirror of
				https://github.com/Instadapp/trustwallet-assets.git
				synced 2024-07-29 22:37:31 +00:00 
			
		
		
		
	 bf24ea2d8b
			
		
	
	
		bf24ea2d8b
		
			
		
	
	
	
	
		
			
			* Force include and exclude implementation. * Rename update to updateAuto * UpdateManual hooks * UpdateManual hook fix * Update existing tokenlist.json file, use exclude/include config. * Force include only pairs against the main currency. * PS config adjustment * Remove tokenlist_base files * Lint fix * Remove all pairs first. Co-authored-by: Catenocrypt <catenocrypt@users.noreply.github.com>
		
			
				
	
	
		
			27 lines
		
	
	
		
			809 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
		
			809 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
| // A single check step
 | |
| export interface CheckStepInterface {
 | |
|     getName(): string;
 | |
|     // return [errors, warnings]
 | |
|     check(): Promise<[string[], string[]]>;
 | |
| }
 | |
| 
 | |
| // An action for a check, fix, or update, or a combination.
 | |
| export interface ActionInterface {
 | |
|     getName(): string;
 | |
|     // return check steps for sanity check (0, 1, or more)
 | |
|     getSanityChecks(): CheckStepInterface[];
 | |
|     // return check steps for consistenct check (0, 1, or more)
 | |
|     getConsistencyChecks?(): CheckStepInterface[];
 | |
|     sanityFix?(): Promise<void>;
 | |
|     consistencyFix?(): Promise<void>;
 | |
|     updateAuto?(): Promise<void>; // For regular automatic updates
 | |
|     updateManual?(): Promise<void>; // For occasional manual updates
 | |
| }
 | |
| 
 | |
| export enum FixCheckMode {
 | |
|     CheckSanityOnly = 1,
 | |
|     CheckAll,
 | |
|     FixSanityOnly,
 | |
|     FixAll
 | |
| }
 |