Add error handling to debug button
Added: - Console log when button is clicked - Console log showing button element - Try-catch wrapper around the function - Error logging with stack trace This will show if the button click is detected and where it fails!
This commit is contained in:
@@ -111,7 +111,13 @@
|
||||
if (btnDebugPages) {
|
||||
btnDebugPages.addEventListener('click', (e) => {
|
||||
console.log('🎯 BUTTON CLICKED: Debug Contar Páginas');
|
||||
debugCountPagesForAllManga();
|
||||
console.log('📝 Button element:', btnDebugPages);
|
||||
try {
|
||||
debugCountPagesForAllManga();
|
||||
} catch (error) {
|
||||
console.error('❌❌❌ Error in debugCountPagesForAllManga:', error);
|
||||
console.error('Stack:', error.stack);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
console.error('❌ btnDebugPages not found!');
|
||||
|
||||
Reference in New Issue
Block a user