diff --git a/app/src/main/java/org/schabi/newpipe/error/ErrorActivity.java b/app/src/main/java/org/schabi/newpipe/error/ErrorActivity.java index 2f607b4876a..b5dd37fdd6f 100644 --- a/app/src/main/java/org/schabi/newpipe/error/ErrorActivity.java +++ b/app/src/main/java/org/schabi/newpipe/error/ErrorActivity.java @@ -26,7 +26,7 @@ import org.schabi.newpipe.util.ThemeHelper; import org.schabi.newpipe.util.external_communication.ShareUtils; -import java.time.LocalDateTime; +import java.time.ZonedDateTime; import java.time.format.DateTimeFormatter; import java.util.Arrays; import java.util.stream.Collectors; @@ -67,10 +67,6 @@ public class ErrorActivity extends AppCompatActivity { public static final String ERROR_GITHUB_ISSUE_URL = "https://github.com/TeamNewPipe/NewPipe/issues"; - public static final DateTimeFormatter CURRENT_TIMESTAMP_FORMATTER = - DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm"); - - private ErrorInfo errorInfo; private String currentTimeStamp; @@ -107,7 +103,9 @@ protected void onCreate(final Bundle savedInstanceState) { // important add guru meditation addGuruMeditation(); - currentTimeStamp = CURRENT_TIMESTAMP_FORMATTER.format(LocalDateTime.now()); + // print current time, as zoned ISO8601 timestamp + final ZonedDateTime now = ZonedDateTime.now(); + currentTimeStamp = now.format(DateTimeFormatter.ISO_OFFSET_DATE_TIME); activityErrorBinding.errorReportEmailButton.setOnClickListener(v -> openPrivacyPolicyDialog(this, "EMAIL")); @@ -250,6 +248,9 @@ private String buildMarkdown() { .append("\n* __Content Language:__ ").append(getContentLanguageString()) .append("\n* __App Language:__ ").append(getAppLanguage()) .append("\n* __Service:__ ").append(errorInfo.getServiceName()) + .append("\n* __Timestamp:__ ").append(currentTimeStamp) + .append("\n* __Package:__ ").append(getPackageName()) + .append("\n* __Service:__ ").append(errorInfo.getServiceName()) .append("\n* __Version:__ ").append(BuildConfig.VERSION_NAME) .append("\n* __OS:__ ").append(getOsString()).append("\n"); diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 766491d538a..2c27e6cbb76 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -266,7 +266,7 @@ Report Info: What happened: - What:\\nRequest:\\nContent Language:\\nContent Country:\\nApp Language:\\nService:\\nGMT Time:\\nPackage:\\nVersion:\\nOS version: + What:\\nRequest:\\nContent Language:\\nContent Country:\\nApp Language:\\nService:\\nTimestamp:\\nPackage:\\nVersion:\\nOS version: Your comment (in English): Details: