Remove console.log statements

This commit is contained in:
kwaroran
2024-03-16 14:41:44 +09:00
parent 527520566d
commit e6f6ef829c
15 changed files with 0 additions and 32 deletions

View File

@@ -92,7 +92,6 @@ export function alertToast(msg:string){
}
export function alertWait(msg:string){
console.log(msg)
alertStore.set({
'type': 'wait',
'msg': msg

View File

@@ -104,9 +104,7 @@ async function importCharacterProcess(f:{
alertError(language.errors.noData)
return
}
console.log(parts[4])
const metaData:RccCardMetaData = JSON.parse(Buffer.from(parts[4], 'base64').toString('utf-8'))
console.log(metaData)
if(metaData.usePassword){
const password = await alertInput(language.inputCardPassword)
if(!password){
@@ -813,7 +811,6 @@ export async function getRisuHub(arg:{
if(da.status !== 200){
return []
}
console.log(da)
return da.json()
} catch (error) {
return[]

View File

@@ -96,7 +96,6 @@ export async function addCharEmotion(charId:number) {
}
let db = get(DataBase)
for(const f of selected){
console.log(f)
const img = f.data
const imgp = await saveImage(img)
const name = f.name.replace('.png','').replace('.webp','')
@@ -130,7 +129,6 @@ export async function exportChat(page:number){
const chat = db.characters[selectedID].chats[page]
const char = db.characters[selectedID]
const date = new Date().toJSON();
console.log(mode)
if(mode === '0'){
const stringl = Buffer.from(JSON.stringify({
type: 'risuChat',
@@ -441,7 +439,6 @@ export async function makeGroupImage() {
// Return the image URI
const uri = canvas.toDataURL()
console.log(uri)
canvas.remove()
db.characters[charID].image = await saveImage(dataURLtoBuffer(uri));
setDatabase(db)

View File

@@ -35,7 +35,6 @@ async function createBotFromWebMain(prompt:string):Promise<creationResult>{
}
const searchDom = new DOMParser()
const searchDoc = searchDom.parseFromString(Buffer.from(bd.data).toString('utf-8'), 'text/html')
console.log(searchDoc)
const links = searchDoc.querySelectorAll(".link-text")
let url = ''
const fandomURL = /(.+?)\.fandom\.com\/wiki\//g
@@ -50,7 +49,6 @@ async function createBotFromWebMain(prompt:string):Promise<creationResult>{
}
const surl = new URL(lurl)
const charname = surl.pathname.split("/")[2].toLocaleLowerCase()
console.log(charname)
if(charname.includes('main') ||charname.includes('home') || charname.includes('wiki')){
continue
}

View File

@@ -112,7 +112,6 @@ async function parseAdditionalAssets(data:string, char:simpleCharacterArgument|c
data = data.replaceAll(assetRegex, (full:string, type:string, name:string) => {
name = name.toLocaleLowerCase()
if(type === 'emotion'){
console.log(emoPaths, name)
const path = emoPaths[name]
if(!path){
return ''
@@ -615,8 +614,6 @@ const matcher = (p1:string,matcherArg:matcherArg) => {
return "[Cannot get time, previous message was sent in older version]"
}
console.log(message.time)
console.log(previous_message.time)
let duration = message.time - previous_message.time
//output time in format like 10:30:00
let seconds = Math.floor(duration / 1000)

View File

@@ -83,7 +83,6 @@ export const PngChunk = {
const len = data[pos] * 0x1000000 + data[pos+1] * 0x10000 + data[pos+2] * 0x100 + data[pos+3]
const type = data.slice(pos+4,pos+8)
const typeString = new TextDecoder().decode(type)
console.log(typeString, len)
if(arg.checkCrc){
const crc = data[pos+8+len] * 0x1000000 + data[pos+9+len] * 0x10000 + data[pos+10+len] * 0x100 + data[pos+11+len]
const crcCheck = crc32(data.slice(pos+4,pos+8+len))
@@ -120,7 +119,6 @@ export const PngChunk = {
const len = data[pos] * 0x1000000 + data[pos+1] * 0x10000 + data[pos+2] * 0x100 + data[pos+3]
const type = data.slice(pos+4,pos+8)
const typeString = new TextDecoder().decode(type)
console.log(typeString, len)
if(arg.checkCrc){
const crc = data[pos+8+len] * 0x1000000 + data[pos+9+len] * 0x10000 + data[pos+10+len] * 0x100 + data[pos+11+len]
const crcCheck = crc32(data.slice(pos+4,pos+8+len))

View File

@@ -77,7 +77,6 @@ function updateCurrentCharacter(){
ShowVN.set(currentChar?.viewScreen === 'vn')
}
console.log("Character updated")
CurrentCharacter.set(cloneDeep(currentChar))
const simp = createSimpleCharacter(currentChar)

View File

@@ -236,8 +236,6 @@ export async function strongBan(data:string, bias:{[key:number]:number}) {
}
}
}
console.log('strongBan', performance.now() - performace)
console.log('added', Object.keys(bias).length - length)
localStorage.setItem('strongBan_' + data, JSON.stringify(bias))
return bias
}

View File

@@ -162,8 +162,6 @@ function readFileAsUint8Array(file) {
export async function changeFullscreen(){
const db = get(DataBase)
const isFull = await appWindow.isFullscreen()
console.log(isFull)
console.log(db.fullScreen)
if(db.fullScreen && (!isFull)){
await appWindow.setFullscreen(true)
}

View File

@@ -35,7 +35,6 @@ class voiceDetector{
const dataArray = new Uint8Array(this.analyser.frequencyBinCount);
this.analyser.getByteTimeDomainData(dataArray);
const volume = dataArray.reduce((acc, val) => acc + val, 0) / dataArray.length;
console.log(volume);
if (Date.now() - start > 10000) {
this.mediaRecorder.stop();
clearInterval(this.intervalID);