safeExecute function
Implementation
void safeExecute(VoidCallback? callback, {String? context}) {
if (callback == null) return;
try {
callback();
} catch (e, stackTrace) {
_logSecurity(
'Button callback error${context != null ? ' in $context' : ''}: $e',
stackTrace: stackTrace,
);
// In production, you might want to report this to a crash reporting service
}
}