reduce frontend log spam from debug messages

This commit is contained in:
Hazelnoot 2025-05-10 13:20:44 -04:00
parent f42f9ee0b5
commit 87dc73d700
22 changed files with 32 additions and 32 deletions

View file

@ -531,7 +531,7 @@ export function getNoteMenu(props: {
}
const cleanup = () => {
if (_DEV_) console.log('note menu cleanup', cleanups);
if (_DEV_) console.debug('note menu cleanup', cleanups);
for (const cl of cleanups) {
cl();
}

View file

@ -54,7 +54,7 @@ export async function getNoteVersionsMenu(props: { note: Misskey.entities.Note }
});
const cleanup = () => {
if (_DEV_) console.log('note menu cleanup', cleanups);
if (_DEV_) console.debug('note menu cleanup', cleanups);
for (const cl of cleanups) {
cl();
}

View file

@ -443,7 +443,7 @@ export function getUserMenu(user: Misskey.entities.UserDetailed, router: Router
return {
menu: menuItems,
cleanup: () => {
if (_DEV_) console.log('user menu cleanup', cleanups);
if (_DEV_) console.debug('user menu cleanup', cleanups);
for (const cl of cleanups) {
cl();
}

View file

@ -19,7 +19,7 @@ try {
});
} catch (err) {
console.warn(err);
if (_DEV_) console.log('[Intl] Fallback to en-US');
if (_DEV_) console.debug('[Intl] Fallback to en-US');
// Fallback to en-US
_dateTimeFormat = new Intl.DateTimeFormat('en-US', {
@ -42,7 +42,7 @@ try {
_numberFormat = new Intl.NumberFormat(versatileLang);
} catch (err) {
console.warn(err);
if (_DEV_) console.log('[Intl] Fallback to en-US');
if (_DEV_) console.debug('[Intl] Fallback to en-US');
// Fallback to en-US
_numberFormat = new Intl.NumberFormat('en-US');

View file

@ -134,7 +134,7 @@ export function playMisskeySfx(operationType: OperationType) {
if (!succeed && sound.type === '_driveFile_') {
// ドライブファイルが存在しない場合はデフォルトのサウンドを再生する
const soundName = PREF_DEF[`sound_${operationType}`].default.type as Exclude<SoundType, '_driveFile_'>;
if (_DEV_) console.log(`Failed to play sound: ${sound.fileUrl}, so play default sound: ${soundName}`);
if (_DEV_) console.debug(`Failed to play sound: ${sound.fileUrl}, so play default sound: ${soundName}`);
playMisskeySfxFileInternal({
type: soundName,
volume: sound.volume,