From 4304c01e2e78ab08b9367abca1d5a1148c306dcf Mon Sep 17 00:00:00 2001 From: Manuel Wedler Date: Fri, 2 Aug 2024 15:12:56 +0200 Subject: [PATCH] Remove console.logs --- apps/contract-verification/src/app/AppContext.tsx | 4 +--- .../src/app/Verifiers/SourcifyVerifier.ts | 8 -------- apps/contract-verification/src/app/app.tsx | 4 ---- .../src/app/components/ContractDropdown.tsx | 2 -- 4 files changed, 1 insertion(+), 17 deletions(-) diff --git a/apps/contract-verification/src/app/AppContext.tsx b/apps/contract-verification/src/app/AppContext.tsx index 7ae2cb32dd..e40e14cc57 100644 --- a/apps/contract-verification/src/app/AppContext.tsx +++ b/apps/contract-verification/src/app/AppContext.tsx @@ -19,9 +19,7 @@ type AppContextType = { // Provide a default value with the appropriate types const defaultContextValue: AppContextType = { themeType: 'dark', - setThemeType: (themeType: ThemeType) => { - console.log('Calling Set Theme Type') - }, + setThemeType: (themeType: ThemeType) => {}, clientInstance: {} as ContractVerificationPluginClient, settings: { chains: {} }, setSettings: () => {}, diff --git a/apps/contract-verification/src/app/Verifiers/SourcifyVerifier.ts b/apps/contract-verification/src/app/Verifiers/SourcifyVerifier.ts index c9a8f53497..fba0c77c36 100644 --- a/apps/contract-verification/src/app/Verifiers/SourcifyVerifier.ts +++ b/apps/contract-verification/src/app/Verifiers/SourcifyVerifier.ts @@ -48,12 +48,6 @@ export class SourcifyVerifier extends AbstractVerifier { async verify(submittedContract: SubmittedContract, compilerAbstract: CompilerAbstract): Promise { const metadataStr = compilerAbstract.data.contracts[submittedContract.filePath][submittedContract.contractName].metadata const sources = compilerAbstract.source.sources - console.log('selectedFilePath:', submittedContract.filePath) - console.log('selectedContractName:', submittedContract.contractName) - console.log('compilerAbstract:', compilerAbstract) - console.log('selectedContractMetadataStr:', metadataStr) - console.log('chainId:', submittedContract.chainId) - console.log('address:', submittedContract.address) // from { "filename.sol": {content: "contract MyContract { ... }"} } // to { "filename.sol": "contract MyContract { ... }" } @@ -70,8 +64,6 @@ export class SourcifyVerifier extends AbstractVerifier { }, } - console.log(body) - const response = await fetch(new URL(this.apiUrl + '/verify').href, { method: 'POST', headers: { diff --git a/apps/contract-verification/src/app/app.tsx b/apps/contract-verification/src/app/app.tsx index 664d0507d0..b1c81f6b32 100644 --- a/apps/contract-verification/src/app/app.tsx +++ b/apps/contract-verification/src/app/app.tsx @@ -28,15 +28,11 @@ const App = () => { // Fetch compiler artefacts initially plugin.call('compilerArtefacts' as any, 'getAllCompilerAbstracts').then((obj: any) => { - console.log('compilerArtefacts.getAllCompilerAbstracts') - console.log(obj) setCompilationOutput(obj) }) // Subscribe to compilations plugin.on('compilerArtefacts' as any, 'compilationSaved', (compilerAbstracts: { [key: string]: CompilerAbstract }) => { - console.log('compilerArtefacts.compilationSaved') - console.log(compilerAbstracts) setCompilationOutput((prev) => ({ ...(prev || {}), ...compilerAbstracts })) }) diff --git a/apps/contract-verification/src/app/components/ContractDropdown.tsx b/apps/contract-verification/src/app/components/ContractDropdown.tsx index 6b62854d61..73e00904a7 100644 --- a/apps/contract-verification/src/app/components/ContractDropdown.tsx +++ b/apps/contract-verification/src/app/components/ContractDropdown.tsx @@ -19,7 +19,6 @@ export const ContractDropdown: React.FC = ({ label, id, s const { compilationOutput } = useContext(AppContext) useEffect(() => { - console.log('CompiilationOutput chainged', compilationOutput) if (!compilationOutput) return // Otherwise select the first by default const triggerFilePath = Object.keys(compilationOutput)[0] @@ -35,7 +34,6 @@ export const ContractDropdown: React.FC = ({ label, id, s }, [compilationOutput]) const handleSelectContract = (event: React.ChangeEvent) => { - console.log('selecting ', event.target.value) setSelectedContract(JSON.parse(event.target.value)) }