fix: add default value to className if Object is null

This commit is contained in:
Tulis
2025-08-03 10:42:18 +02:00
parent a9d0aea6eb
commit f783f0aba3

View File

@ -31,7 +31,7 @@ public class Errorer {
public void reportException(Exception e, Object o, String... additionalData) {
String stackTrace = getErrorStackTrace(e);
String className = o.getClass().getName();
String className = (o != null) ? o.getClass().getName() : "Static Usage";
String errorText = e.getClass().getName() + " in " + className;
ZonedDateTime warsawTime = ZonedDateTime.now(ZoneId.of("Europe/Warsaw"));