diff --git a/src/providers/Project/projectDefault.ts b/src/providers/Project/projectDefault.ts index 0272c069..e13d9cc0 100644 --- a/src/providers/Project/projectDefault.ts +++ b/src/providers/Project/projectDefault.ts @@ -111,7 +111,7 @@ export function createLocalProject( const accountEntities: Account[] = accounts.map((_account) => { return { __typename: 'Account', - address: _account.padStart(16, "0"), + address: _account.padStart(16, '0'), deployedContracts: [], state: DEFAULT_ACCOUNT_STATE, }; diff --git a/src/util/parser.test.ts b/src/util/parser.test.ts index eb4665bc..0ac22615 100644 --- a/src/util/parser.test.ts +++ b/src/util/parser.test.ts @@ -1,27 +1,24 @@ -import { extractSigners } from "./parser"; +import { extractSigners } from './parser'; const oneSigner = ` transaction { prepare(acct: auth(LoadValue, SaveValue) &Account) {} -}` - +}`; const twoSigners = ` transaction { prepare(authorizer1: auth(Capabilities,SomethingElse) &Account, authorizer2: auth(Storage,Vaults) &Account) { } -}` +}`; describe('parser tests', () => { it('should extract one code signer', () => { + const signers = extractSigners(oneSigner); - const signers = extractSigners(oneSigner) - - expect(signers).toHaveLength(1) - }) + expect(signers).toHaveLength(1); + }); it('should extract two code signer', () => { + const signers = extractSigners(twoSigners); - const signers = extractSigners(twoSigners) - - expect(signers).toHaveLength(2) - }) -}) + expect(signers).toHaveLength(2); + }); +}); diff --git a/src/util/parser.ts b/src/util/parser.ts index f649f260..6188b674 100644 --- a/src/util/parser.ts +++ b/src/util/parser.ts @@ -9,7 +9,7 @@ export const generateSchema = (argsDefinition: string) => return match.replace(/,/g, ''); }) .split(',') - .map((item) => item.replace(/\s*/g, '').replace(//g,',')) + .map((item) => item.replace(/\s*/g, '').replace(//g, ',')) .filter((item) => item !== ''); export const stripComments = (code: string) => {