clear console log

pull/5065/head
Joseph Izang 3 months ago committed by Aniket
parent b764cbabbd
commit 8886c10649
  1. 5
      libs/remix-ui/workspace/src/lib/actions/index.ts
  2. 2
      libs/remix-ui/workspace/src/lib/remix-ui-workspace.tsx

@ -274,7 +274,6 @@ const buildGistPayload = (selectedFiles: { key: string, type: 'file' | 'folder',
export const publishFilesToGist = (arrayOfSelectedFiles: any) => { export const publishFilesToGist = (arrayOfSelectedFiles: any) => {
const gistPayload = buildGistPayload(arrayOfSelectedFiles) const gistPayload = buildGistPayload(arrayOfSelectedFiles)
if (!gistPayload) { if (!gistPayload) {
console.error('No files to publish');
return; return;
} }
console.log('primed and ready', gistPayload) console.log('primed and ready', gistPayload)
@ -296,7 +295,6 @@ export const publishFilesToGist = (arrayOfSelectedFiles: any) => {
public: true, public: true,
files: gistPayload files: gistPayload
}, (error, result) => { }, (error, result) => {
console.log('what comes back from gist creation', { error, result })
handleGistResponse(error, result) handleGistResponse(error, result)
}) })
console.log('publishFilesToGistIsDone') console.log('publishFilesToGistIsDone')
@ -318,7 +316,6 @@ export const publishToGist = async (path?: string) => {
id = await plugin.call('filePanel', 'isGist') id = await plugin.call('filePanel', 'isGist')
} }
const packaged = await packageGistFiles(folder) const packaged = await packageGistFiles(folder)
console.log('packed files', packaged)
// check for token // check for token
const config = plugin.registry.get('config').api const config = plugin.registry.get('config').api
const accessToken = config.get('settings/gist-access-token') const accessToken = config.get('settings/gist-access-token')
@ -370,7 +367,6 @@ export const publishToGist = async (path?: string) => {
public: true, public: true,
files: packaged files: packaged
}, (error, result) => { }, (error, result) => {
console.log('what comes back from gist creation', { error, result })
handleGistResponse(error, result) handleGistResponse(error, result)
}) })
} }
@ -585,7 +581,6 @@ export const restoreBackupZip = async () => {
const packageGistFiles = async (directory) => { const packageGistFiles = async (directory) => {
const workspaceProvider = plugin.fileProviders.workspace const workspaceProvider = plugin.fileProviders.workspace
const isFile = await workspaceProvider.isFile(directory) const isFile = await workspaceProvider.isFile(directory)
console.log('here is the state of things in packageGistFiles', { directory, isFile })
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
const ret = {} const ret = {}

@ -174,7 +174,6 @@ export function Workspace() {
const content = await global.plugin.call('fileManager', 'readFile', one.key) const content = await global.plugin.call('fileManager', 'readFile', one.key)
selectedFiles.push({ key: one.key, type: one.type, content: content }) selectedFiles.push({ key: one.key, type: one.type, content: content })
} }
console.log('Files selected', selectedFiles)
global.dispatchPublishFilesToGist(selectedFiles) global.dispatchPublishFilesToGist(selectedFiles)
} catch (error) { } catch (error) {
await global.plugin.call('notification', 'toast', 'Could not publish files to gist. There was an error') await global.plugin.call('notification', 'toast', 'Could not publish files to gist. There was an error')
@ -184,7 +183,6 @@ export function Workspace() {
useEffect(() => { useEffect(() => {
global.plugin.on('finishedGistPublish', (folderName) => { global.plugin.on('finishedGistPublish', (folderName) => {
console.log('finished publishing to gist', folderName)
}) })
}, []) }, [])

Loading…
Cancel
Save