diff --git a/backend/DummyD/dummyDataMain.ts b/backend/DummyD/dummyDataMain.ts index bd45aa20..551e44aa 100644 --- a/backend/DummyD/dummyDataMain.ts +++ b/backend/DummyD/dummyDataMain.ts @@ -29,7 +29,7 @@ const getRandomInt = (min: number, max: number) => { const generateDataByType = (columnObj: ColumnObj): string | number => { let length; // faker.js method to generate data by type - console.log('columnObj_datatype: ', columnObj.data_type) + // console.log('columnObj_datatype: ', columnObj.data_type) switch (columnObj.data_type) { case 'smallint': diff --git a/backend/Logging/masterlog.ts b/backend/Logging/masterlog.ts index f46a9030..5f36b3ae 100644 --- a/backend/Logging/masterlog.ts +++ b/backend/Logging/masterlog.ts @@ -62,10 +62,10 @@ const logger = function ( if (opt1) moreText += JSON.stringify(opt1); if (opt2) moreText += JSON.stringify(opt2); - console.log( - `\u001b[1;${colorCode}m ${`[${logType}] ${message + moreText}`}` + - `\u001b[1;0m` - ); + // console.log( + // `\u001b[1;${colorCode}m ${`[${logType}] ${message + moreText}`}` + + // `\u001b[1;0m` + // ); saveLogMessage(`[${logType}] ${message}`); }; diff --git a/backend/channels.ts b/backend/channels.ts index 8ebb1d9e..583581a6 100644 --- a/backend/channels.ts +++ b/backend/channels.ts @@ -121,7 +121,7 @@ ipcMain.handle( event.sender.send('async-started'); try { - console.log('dbName from backend', dbName, 'dbType from backend'); + // console.log('dbName from backend', dbName, 'dbType from backend'); await db.connectToDB(dbName, dbType); @@ -199,7 +199,7 @@ ipcMain.handle( const dumpCmd = withData ? runFullCopyFunc(sourceDb, tempFilePath, dbType) : runHollowCopyFunc(sourceDb, tempFilePath, dbType); - console.log('dbType for importing a database', dbType); + // console.log('dbType for importing a database', dbType); try { await promExecute(dumpCmd); } catch (e) { @@ -334,7 +334,7 @@ ipcMain.handle( null, dbType ); - console.log(LogType.WARNING, results); + // console.log(LogType.WARNING, results); explainResults = results[1].rows; } else if (dbType === DBType.MySQL) { const results = await db.query( @@ -345,7 +345,7 @@ ipcMain.handle( explainResults = results[0][0]; // console.log('mysql explain results', explainResults); - console.log(LogType.WARNING, results); + // console.log(LogType.WARNING, results); } } catch (e) { error = `Failed to get Execution Plan. EXPLAIN might not support this query.`; @@ -358,7 +358,7 @@ ipcMain.handle( if (dbType === DBType.MySQL) { returnedRows = results[0][1]; - console.log('returnedRows in channels for MySQL', returnedRows); + // console.log('returnedRows in channels for MySQL', returnedRows); } if (dbType === DBType.Postgres) { // console.log('results in channels for Postgres', results); @@ -446,24 +446,24 @@ ipcMain.handle( // generate dummy data logger("Received 'generate-dummy-data'", LogType.RECEIVE); // send notice to front end that DD generation has been started event.sender.send('async-started'); - console.log('genereatedata ipcMain dbType: ', dbType) + // console.log('genereatedata ipcMain dbType: ', dbType) let feedback: Feedback = { type: '', message: '', }; try { - console.log('data in generate-dummy-data', data); // gets here fine + // console.log('data in generate-dummy-data', data); // gets here fine // Retrieves the Primary Keys and Foreign Keys for all the tables const tableInfo: ColumnObj[] = await db.getTableInfo(data.tableName, dbType); // passed in dbType to second argument - console.log('tableInfo in generate-dummy-data', tableInfo); // working + // console.log('tableInfo in generate-dummy-data', tableInfo); // working // generate dummy data const dummyArray: DummyRecords = await generateDummyData( tableInfo, data.rows ); - console.log('dummyArray output: ', dummyArray) + // console.log('dummyArray output: ', dummyArray) // generate insert query string to insert dummy records const columnsStringified = '(' .concat(dummyArray[0].join(', ')) @@ -495,10 +495,10 @@ ipcMain.handle( // generate dummy data message: err, }; } finally { - console.log('dbType inside generate-dummy-data', dbType) + // console.log('dbType inside generate-dummy-data', dbType) // send updated db info in case query affected table or database information const dbsAndTables: DBList = await db.getLists('', dbType); // dummy data clear error is from here - console.log('dbsAndTables in generate-dummy-data', dbsAndTables) + // console.log('dbsAndTables in generate-dummy-data', dbsAndTables) event.sender.send('db-lists', dbsAndTables); // dummy data clear error is from here // send feedback back to FE diff --git a/backend/helperFunctions.ts b/backend/helperFunctions.ts index 6cde7088..377f5d55 100644 --- a/backend/helperFunctions.ts +++ b/backend/helperFunctions.ts @@ -34,8 +34,8 @@ const helperFunctions: HelperFunctions = { const PG = `CREATE DATABASE "${name}"`; const MYSQL = `CREATE DATABASE ${name}`; - console.log('RETURNING DB: ', DBType.Postgres ? PG : MYSQL); - console.log(dbType); + // console.log('RETURNING DB: ', DBType.Postgres ? PG : MYSQL); + // console.log(dbType); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -45,8 +45,8 @@ const helperFunctions: HelperFunctions = { const PG = `DROP DATABASE "${dbName}"`; const MYSQL = `DROP DATABASE ${dbName}`; - console.log(`dropDBFunc MySQL: ${MYSQL}, ${dbType}`); - console.log(`dropDBFunc PG: ${MYSQL}, ${dbType}`); + // console.log(`dropDBFunc MySQL: ${MYSQL}, ${dbType}`); + // console.log(`dropDBFunc PG: ${MYSQL}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -56,8 +56,8 @@ const helperFunctions: HelperFunctions = { const PG = `BEGIN; EXPLAIN (FORMAT JSON, ANALYZE, VERBOSE, BUFFERS) ${sqlString}; ROLLBACK`; const MYSQL = `BEGIN; EXPLAIN ANALYZE ${sqlString}`; - console.log(`explainQuery MySQL: ${MYSQL}, ${dbType}`); - console.log(`explainQuery PG: ${MYSQL}, ${dbType}`); + // console.log(`explainQuery MySQL: ${MYSQL}, ${dbType}`); + // console.log(`explainQuery PG: ${MYSQL}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -65,13 +65,13 @@ const helperFunctions: HelperFunctions = { // import SQL file into new DB created runSQLFunc: function (dbName, file, dbType: DBType) { const SQL_data = docConfig.getFullConfig(); - console.log(SQL_data) + // console.log(SQL_data) const PG = `PGPASSWORD=${SQL_data.pg_pass} psql -U ${SQL_data.pg_user} -d "${dbName}" -f "${file}" -p ${SQL_data.pg_port}`; // const MYSQL = `mysql -u root -p ${dbName} < ${file}`; const MYSQL = `export MYSQL_PWD='${SQL_data.mysql_pass}'; mysql -u${SQL_data.mysql_user} --port=${SQL_data.mysql_port} ${dbName} < ${file}`; - console.log(`runSQLFunc MySQL: ${MYSQL}, ${dbType}`); - console.log(`runSQLFunc PG: ${PG}, ${dbType}`); + // console.log(`runSQLFunc MySQL: ${MYSQL}, ${dbType}`); + // console.log(`runSQLFunc PG: ${PG}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -82,8 +82,8 @@ const helperFunctions: HelperFunctions = { const PG = `PGPASSWORD=${SQL_data.pg_pass} pg_restore -U ${SQL_data.pg_user} -p ${SQL_data.pg_port} -d "${dbName}" "${file}" `; const MYSQL = `export MYSQL_PWD='${SQL_data.mysql_pass}'; mysqldump -u ${SQL_data.mysql_user} --port=${SQL_data.mysql_port} ${dbName} > ${file}`; - console.log(`runTARFunc MySQL: ${MYSQL}, ${dbType}`); - console.log(`runTARFunc PG: ${PG}, ${dbType}`); + // console.log(`runTARFunc MySQL: ${MYSQL}, ${dbType}`); + // console.log(`runTARFunc PG: ${PG}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -94,8 +94,8 @@ const helperFunctions: HelperFunctions = { const PG = `PGPASSWORD=${SQL_data.pg_pass} pg_dump -s -U ${SQL_data.pg_user} -p ${SQL_data.pg_port} -Fp -d ${dbCopyName} > "${newFile}"`; const MYSQL = `export MYSQL_PWD='${SQL_data.mysql_pass}'; mysqldump -h localhost -u ${SQL_data.mysql_user} ${dbCopyName} > ${newFile}`; - console.log(`runFullCopyFunc MySQL: ${MYSQL}, ${dbType}`); - console.log(`runFullCopyFunc PG: ${PG}, ${dbType}`); + // console.log(`runFullCopyFunc MySQL: ${MYSQL}, ${dbType}`); + // console.log(`runFullCopyFunc PG: ${PG}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -106,8 +106,8 @@ const helperFunctions: HelperFunctions = { const PG = ` PGPASSWORD=${SQL_data.pg_pass} pg_dump -s -U ${SQL_data.pg_user} -p ${SQL_data.pg_port} -F p -d "${dbCopyName}" > "${file}"`; const MYSQL = `export MYSQL_PWD='${SQL_data.mysql_pass}'; mysqldump -h localhost -u ${SQL_data.mysql_user} --port=${SQL_data.mysql_port} ${dbCopyName} > ${file}`; - console.log(`runHollowCopyFunc MySQL: ${MYSQL}, ${dbType}`); - console.log(`runHollowCopyFunc PG: ${PG}, ${dbType}`); + // console.log(`runHollowCopyFunc MySQL: ${MYSQL}, ${dbType}`); + // console.log(`runHollowCopyFunc PG: ${PG}, ${dbType}`); return dbType === DBType.Postgres ? PG : MYSQL; }, @@ -116,7 +116,7 @@ const helperFunctions: HelperFunctions = { new Promise((resolve, reject) => { exec(cmd, {timeout: 5000}, (error, stdout, stderr) => { if (error){ - console.log(error) + // console.log(error) return reject(error)}; if (stderr) return reject(new Error(stderr)); return resolve({ stdout, stderr }); diff --git a/backend/models.ts b/backend/models.ts index 74786dd0..4e3b8df0 100644 --- a/backend/models.ts +++ b/backend/models.ts @@ -226,7 +226,7 @@ const getDBLists = function ( const tableList: TableDetails[] = []; const promiseArray: Promise[] = []; - console.log('dbType - getDBLists: ', dbType); + // console.log('dbType - getDBLists: ', dbType); if (dbType === DBType.Postgres) { @@ -325,7 +325,7 @@ const PG_DBConnect = async function (pg_uri: string, db: string) { }; const MSQL_DBConnect = function (db: string) { - console.log(`mysql dbconnect ${db}`); + // console.log(`mysql dbconnect ${db}`); msql_pool .query(`USE ${db};`) .then(() => { @@ -416,7 +416,7 @@ const myObj: MyObj = { resolve(data); }) .catch((err) => { - console.log(`Double: ${this.curMSQL_DB}`); + // console.log(`Double: ${this.curMSQL_DB}`); logger(err.message, LogType.WARNING, 'dbQuery1'); reject(err); }); @@ -429,7 +429,7 @@ const myObj: MyObj = { resolve(data); }) .catch((err) => { - console.log(`Double none: ${this.curMSQL_DB}`); + // console.log(`Double none: ${this.curMSQL_DB}`); logger(err.message, LogType.WARNING, 'mysql caught'); reject(err); }); @@ -459,7 +459,7 @@ const myObj: MyObj = { this.curPG_DB = db; await PG_DBConnect(this.pg_uri, db); } else if (dbType === DBType.MySQL) { - console.log(`connectToDB -- : ${this.curMSQL_DB}`); + // console.log(`connectToDB -- : ${this.curMSQL_DB}`); this.curMSQL_DB = db; await MSQL_DBConnect(db); } @@ -505,7 +505,7 @@ const myObj: MyObj = { }) .finally(() => { if (dbType) { - console.log('dbType is defined') + // console.log('dbType is defined') getDBLists(dbType, dbName) // dbLists returning empty array - DBType is not defined .then((data) => { logger( @@ -522,7 +522,7 @@ const myObj: MyObj = { ); }); } else { - console.log('dbType is not defined') + // console.log('dbType is not defined') logger('RESOLVING DB DETAILS: Only DB Names', LogType.SUCCESS); resolve(listObj); } diff --git a/frontend/components/App.tsx b/frontend/components/App.tsx index e60525af..29360fe7 100644 --- a/frontend/components/App.tsx +++ b/frontend/components/App.tsx @@ -73,7 +73,7 @@ const App = () => { const [showConfigDialog, setConfigDialog] = useState(false); useEffect(() => { - console.log('dbTables:', dbTables, 'selectedTable: ', selectedTable, 'selectedDb: ', selectedDb, 'curDBType: ', curDBType, 'DBInfo: ', DBInfo, 'PG_isConnected: ', PG_isConnected, 'MYSQL_isConnected: ', MYSQL_isConnected); + // console.log('dbTables:', dbTables, 'selectedTable: ', selectedTable, 'selectedDb: ', selectedDb, 'curDBType: ', curDBType, 'DBInfo: ', DBInfo, 'PG_isConnected: ', PG_isConnected, 'MYSQL_isConnected: ', MYSQL_isConnected); // Listen to backend for updates to list of available databases const dbListFromBackend = (evt: IpcRendererEvent, dbLists: DbLists) => { if (isDbLists(dbLists)) { diff --git a/frontend/components/Dialog/ConfigView.tsx b/frontend/components/Dialog/ConfigView.tsx index 2bc55aa9..66df7712 100644 --- a/frontend/components/Dialog/ConfigView.tsx +++ b/frontend/components/Dialog/ConfigView.tsx @@ -2,32 +2,49 @@ import React, { useState, useEffect } from 'react'; import { DatabaseInfo, DBType } from '../../types'; import { IpcRendererEvent, ipcRenderer } from 'electron'; import styled from 'styled-components'; -import { TextField, Box, InputLabel, Select, DialogTitle } from '@material-ui/core/'; -import { Button, Dialog, FormControl, IconButton, InputAdornment, MenuItem, Tooltip } from '@mui/material'; +import { + TextField, + Box, + InputLabel, + Select, + DialogTitle, +} from '@material-ui/core/'; +import { + Button, + Dialog, + FormControl, + IconButton, + InputAdornment, + MenuItem, + Tooltip, +} from '@mui/material'; import { sendFeedback } from '../../lib/utils'; import { - ButtonContainer, - TextFieldContainer, - StyledButton, - StyledTextField, - DropdownContainer, - StyledDropdown, - StyledMenuItem, - StyledInputLabel, - StyledNativeDropdown, - StyledNativeOption, - } from '../../style-variables'; + ButtonContainer, + TextFieldContainer, + StyledButton, + StyledTextField, + DropdownContainer, + StyledDropdown, + StyledMenuItem, + StyledInputLabel, + StyledNativeDropdown, + StyledNativeOption, +} from '../../style-variables'; import { once } from '../../lib/utils'; import { Visibility, VisibilityOff } from '@mui/icons-material'; -const requestConfig = once(() => ipcRenderer.invoke('get-config')); + +const requestConfig = once(() => { + // console.log('is this running once?'); + return ipcRenderer.invoke('get-config'); +}); interface ConfigViewProps { - show: boolean; - onClose: () => void; + show: boolean; + onClose: () => void; } const ConfigView = ({ show, onClose }: ConfigViewProps) => { - const [mysql_user, setMySQL_User] = useState(''); const [mysql_pass, setMySQL_Pass] = useState(''); const [mysql_port, setMySQL_Port] = useState(''); @@ -64,165 +81,172 @@ const ConfigView = ({ show, onClose }: ConfigViewProps) => { const handleSubmit = () => { //it needs to be as any because otherwise typescript thinks it doesn't have a 'value' param idk why ipcRenderer - .invoke('set-config', - { - mysql_user, - mysql_pass, - mysql_port: parseInt(mysql_port), - pg_user, - pg_pass, - pg_port: parseInt(pg_port) - }) - .then(() => { + .invoke('set-config', { + mysql_user, + mysql_pass, + mysql_port: parseInt(mysql_port), + pg_user, + pg_pass, + pg_port: parseInt(pg_port), + }) + .then(() => { handleClose(); - }) - .catch((err) => { + }) + .catch((err) => { sendFeedback({ - type: 'error', - message: err ?? 'Failed to save config.', + type: 'error', + message: err ?? 'Failed to save config.', }); - }); -} + }); + }; if (!show) return null; return (
- + > - - Configure SeeQR - - - {setMySQL_User(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - }} - defaultValue={mysql_user} - /> - - {setMySQL_Pass(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - endAdornment: ( - - setMySQL_ShowPass(!mysql_showpass)} - onMouseDown={() => setMySQL_ShowPass(!mysql_showpass)} - > - {mysql_showpass ? : } - - - ) - }} - defaultValue={mysql_pass} - /> - - {setMySQL_Port(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - }} - defaultValue={mysql_port} - /> - - {setPG_User(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - }} - defaultValue={pg_user} - /> - - {setPG_Pass(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - endAdornment: ( - - setPG_ShowPass(!pg_showpass)} - onMouseDown={() => setPG_ShowPass(!pg_showpass)} - > - {pg_showpass ? : } - - - ) - }} - defaultValue={pg_pass} - /> - - {setPG_Port(event.target.value)}} - InputProps={{ - style: { color: '#575151' }, - }} - defaultValue={pg_port} - /> + Configure SeeQR + + { + setMySQL_User(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + }} + defaultValue={mysql_user} + /> + + { + setMySQL_Pass(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + endAdornment: ( + + setMySQL_ShowPass(!mysql_showpass)} + onMouseDown={() => setMySQL_ShowPass(!mysql_showpass)} + > + {mysql_showpass ? : } + + + ), + }} + defaultValue={mysql_pass} + /> + + { + setMySQL_Port(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + }} + defaultValue={mysql_port} + /> + + { + setPG_User(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + }} + defaultValue={pg_user} + /> + + { + setPG_Pass(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + endAdornment: ( + + setPG_ShowPass(!pg_showpass)} + onMouseDown={() => setPG_ShowPass(!pg_showpass)} + > + {pg_showpass ? : } + + + ), + }} + defaultValue={pg_pass} + /> + + { + setPG_Port(event.target.value); + }} + InputProps={{ + style: { color: '#575151' }, + }} + defaultValue={pg_port} + /> - - + > Cancel - + - + > Save - + - - -
+ + ); }; diff --git a/frontend/components/modal/AddNewDbModalCorrect.tsx b/frontend/components/modal/AddNewDbModalCorrect.tsx index 9b36b43e..e864b01e 100644 --- a/frontend/components/modal/AddNewDbModalCorrect.tsx +++ b/frontend/components/modal/AddNewDbModalCorrect.tsx @@ -83,9 +83,9 @@ const AddNewDbModal = ({ // Opens modal to select file and sends the selected file to backend const handleFileClick = () => { const dbt: DBType = (document.getElementById('dbTypeDropdown') as any).value; - console.log('curDBType in addnewdbmodalcorrect', curDBType) - console.log('newdbName in addnewdbmodalcorrect', newDbName) - console.log('dbt in addnewdbmodalcorrect', dbt) + // console.log('curDBType in addnewdbmodalcorrect', curDBType) + // console.log('newdbName in addnewdbmodalcorrect', newDbName) + // console.log('dbt in addnewdbmodalcorrect', dbt) dialog .showOpenDialog({ properties: ['openFile'], @@ -117,7 +117,7 @@ const AddNewDbModal = ({ ); }) .catch((err: object) => { - console.log(err); + // console.log(err); }) .finally(handleClose); }; diff --git a/frontend/components/modal/DummyDataModal.tsx b/frontend/components/modal/DummyDataModal.tsx index 0a991d3e..f07ca50e 100644 --- a/frontend/components/modal/DummyDataModal.tsx +++ b/frontend/components/modal/DummyDataModal.tsx @@ -36,7 +36,7 @@ const DummyDataModal = ({ const [isError, setIsError] = useState(false); const [isEmpty, setIsEmpty] = useState(true); - console.log('curDBType:', curDBType); + // console.log('curDBType:', curDBType); const handleClose = () => { @@ -105,7 +105,7 @@ const DummyDataModal = ({ }) ) .catch((err: object) => { - console.log(err); + // console.log(err); }) .finally(handleClose); }; diff --git a/frontend/components/sidebar/QueryList.tsx b/frontend/components/sidebar/QueryList.tsx index ef21e91c..06666e55 100644 --- a/frontend/components/sidebar/QueryList.tsx +++ b/frontend/components/sidebar/QueryList.tsx @@ -123,7 +123,7 @@ const QueryList = ({ } return undefined; }).catch((err: object | undefined) => { - console.log(err); + // console.log(err); return undefined; }); } @@ -149,7 +149,7 @@ const QueryList = ({ } return undefined; }).catch((err: object) => { - console.log(err); + // console.log(err); return undefined; }); } diff --git a/frontend/components/views/DbView/DbView.tsx b/frontend/components/views/DbView/DbView.tsx index 57d2b359..4939b094 100644 --- a/frontend/components/views/DbView/DbView.tsx +++ b/frontend/components/views/DbView/DbView.tsx @@ -37,7 +37,7 @@ const DbView = ({ selectedDb, show, setERView, ERView, curDBType, setDBType, DBI const [open, setOpen] = useState(false); -console.log('DB props', curDBType, selectedDb) +// console.log('DB props', curDBType, selectedDb) const handleClickOpen = () => { diff --git a/frontend/components/views/QueryView/QueryResults.tsx b/frontend/components/views/QueryView/QueryResults.tsx index b81071d9..758eff85 100644 --- a/frontend/components/views/QueryView/QueryResults.tsx +++ b/frontend/components/views/QueryView/QueryResults.tsx @@ -35,14 +35,14 @@ const buildColumns = (row: Record): Column[] => name: column, align: isNumber(value) ? 'right' : 'left', })); -console.log('buildColumns: QueryResults', buildColumns); +// console.log('buildColumns: QueryResults', buildColumns); interface QueryResultsProps { results: QueryData['returnedRows']; } const QueryResults = ({ results }: QueryResultsProps) => { if (!results || !results.length) return null; - console.log('Results: QueryResults', results); + // console.log('Results: QueryResults', results); const [page, setPage] = React.useState(0); const rowsPerPage = 10; diff --git a/frontend/components/views/QueryView/QueryView.tsx b/frontend/components/views/QueryView/QueryView.tsx index 79f9fbe9..39d9d561 100644 --- a/frontend/components/views/QueryView/QueryView.tsx +++ b/frontend/components/views/QueryView/QueryView.tsx @@ -102,11 +102,11 @@ const QueryView = ({ // request updates for db and table information. Otherwise database view tab // will show wrong information - console.log( - 'when selecting a database from the dropdown menu, we first go here in queryview' - ); - console.log('nextDBType in QueryView', nextDBType); - console.log('newDB in Query View', newDb); + // console.log( + // 'when selecting a database from the dropdown menu, we first go here in queryview' + // ); + // console.log('nextDBType in QueryView', nextDBType); + // console.log('newDB in Query View', newDb); setSelectedDb(newDb); setDBType(nextDBType); @@ -130,7 +130,7 @@ const QueryView = ({ }; const onRun = () => { - console.log('onRun is called'); + // console.log('onRun is called'); if (!localQuery.label.trim()) { sendFeedback({ type: 'info', @@ -161,10 +161,10 @@ const QueryView = ({ throw error; } let transformedData; - console.log('returnedRows after .then method', returnedRows); - console.log('explainResult after .then method', explainResults); + // console.log('returnedRows after .then method', returnedRows); + // console.log('explainResult after .then method', explainResults); - console.log('curDBType in QueryView', curDBType); + // console.log('curDBType in QueryView', curDBType); if (curDBType === DBType.Postgres) { transformedData = { diff --git a/frontend/lib/queries.ts b/frontend/lib/queries.ts index e71143c2..ec4b1bba 100644 --- a/frontend/lib/queries.ts +++ b/frontend/lib/queries.ts @@ -68,7 +68,7 @@ export const getAppDataPath: GetAppDataPath = () => { return path.join(process.env.HOME, ".SeeQR Data.json"); } default: { - console.log("Unsupported platform!"); + // console.log("Unsupported platform!"); process.exit(1); } } @@ -95,7 +95,7 @@ export const saveQuery:SaveQuery = ( query: QueryData, filePath: string) => { console.log(err); }; } else { - console.log('File is found'); + // console.log('File is found'); const data: object = JSON.parse(fs.readFileSync(filePath)); const label: string = `label:${query.label} db:${query.db} group:${query.group}` data[label] = query;