Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Nextcloud - Android Client
*
* SPDX-FileCopyrightText: 2023-2024 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-FileCopyrightText: 2023-2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-FileCopyrightText: 2019-2021 Tobias Kaminsky <tobias@kaminsky.me>
* SPDX-FileCopyrightText: 2018 Andy Scherzinger <info@andy-scherzinger>
* SPDX-FileCopyrightText: 2017 Mario Danic <mario@lovelyhq.com>
Expand Down Expand Up @@ -1171,7 +1171,7 @@ public void onAuthenticatorTaskCallback(RemoteOperationResult<UserInfo> result)
if (accountSetupWebviewBinding != null) {
anonymouslyPostLoginRequest(mServerInfo.mBaseUrl + WEB_LOGIN);
} else {
DisplayUtils.showSnackMessage(this, R.string.auth_access_failed, result.getLogMessage());
DisplayUtils.showSnackMessage(this, R.string.auth_access_failed, result.getLogMessage(this));

// init webView again
updateAuthStatusIconAndText(result);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Nextcloud - Android Client
*
* SPDX-FileCopyrightText: 2023 Alper Ozturk <alper.ozturk@nextcloud.com>
* SPDX-FileCopyrightText: 2022 TSI-mc
* SPDX-FileCopyrightText: 2022-2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-FileCopyrightText: 2021 Chris Narkiewicz <hello@ezaquarii.com>
* SPDX-FileCopyrightText: 2018-2020 Tobias Kaminsky <tobias@kaminsky.me>
* SPDX-FileCopyrightText: 2018 Andy Scherzinger <info@andy-scherzinger.de>
Expand Down Expand Up @@ -567,7 +567,7 @@ public OCFile saveFileWithParent(OCFile ocFile, Context context) {
} else {
Exception exception = result.getException();
String message = "Error during saving file with parents: " + ocFile.getRemotePath() + " / "
+ result.getLogMessage();
+ result.getLogMessage(context);

if (exception != null) {
throw new RemoteOperationFailedException(message, exception);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
*
* SPDX-FileCopyrightText: 2019 Chris Narkiewicz <hello@ezaquarii.com>
* SPDX-FileCopyrightText: 2018 Edvard Holst <edvard.holst@gmail.com>
* SPDX-FileCopyrightText: 2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
*/
package com.owncloud.android.ui.activities.data.activities;
Expand Down Expand Up @@ -94,7 +95,7 @@ protected Boolean doInBackground(Void... voids) {
} else {
Log_OC.d(TAG, result.getLogMessage());
// show error
errorMessage = result.getLogMessage();
errorMessage = result.getLogMessage(MainApp.getAppContext());
if (result.getHttpCode() == HttpStatus.SC_NOT_MODIFIED) {
errorMessage = context.getString(R.string.file_list_empty_headline_server_search);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2020 Chris Narkiewicz <hello@ezaquarii.com>
* SPDX-FileCopyrightText: 2017 Mario Danic <mario@lovelyhq.com>
* SPDX-FileCopyrightText: 2017 Nextcloud GmbH
* SPDX-FileCopyrightText: 2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
*/
package com.owncloud.android.ui.activity
Expand Down Expand Up @@ -259,7 +260,7 @@ class NotificationsActivity : AppCompatActivity(), NotificationsContract.View, I
runOnUiThread {
setEmptyContent(
getString(R.string.notifications_no_results_headline),
result?.logMessage
result?.getLogMessage(this)
)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* SPDX-FileCopyrightText: 2018 Tobias Kaminsky <tobias@kaminsky.me>
* SPDX-FileCopyrightText: 2017 Mario Danic <mario@lovelyhq.com>
* SPDX-FileCopyrightText: 2017 Nextcloud GmbH
* SPDX-FileCopyrightText: 2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
*/
package com.owncloud.android.ui.activity;
Expand Down Expand Up @@ -317,7 +318,7 @@ private void fetchAndSetData() {
// show error
runOnUiThread(() -> setErrorMessageForMultiList(
getString(R.string.user_information_retrieval_error),
result.getLogMessage(),
result.getLogMessage(this),
R.drawable.ic_list_empty_error)
);
Log_OC.d(TAG, result.getLogMessage());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@
*
* SPDX-FileCopyrightText: 2019 Tobias Kaminsky <tobias@kaminsky.me>
* SPDX-FileCopyrightText: 2019 Nextcloud GmbH
* SPDX-FileCopyrightText: 2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
*/
package com.owncloud.android.ui.asynctasks;

import android.os.AsyncTask;

import com.nextcloud.client.account.User;
import com.owncloud.android.MainApp;
import com.owncloud.android.R;
import com.owncloud.android.datamodel.FileDataStorageManager;
import com.owncloud.android.datamodel.OCFile;
Expand Down Expand Up @@ -60,7 +62,7 @@ protected String doInBackground(Void... voids) {

if (!result.isSuccess()) {
Exception exception = result.getException();
String message = "Fetching file " + remotePath + " fails with: " + result.getLogMessage();
String message = "Fetching file " + remotePath + " fails with: " + result.getLogMessage(MainApp.getAppContext());

if (exception != null) {
return exception.getMessage();
Expand Down Expand Up @@ -95,7 +97,7 @@ protected String doInBackground(Void... voids) {

fileDisplayActivity.setFile(ocFile);
} else {
return remoteOperationResult.getLogMessage();
return remoteOperationResult.getLogMessage(MainApp.getAppContext());
}

return "";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
*
* SPDX-FileCopyrightText: 2019 Chris Narkiewicz <hello@ezaquarii.com>
* SPDX-FileCopyrightText: 2018 Andy Scherzinger <info@andy-scherzinger.de>
* SPDX-FileCopyrightText: 2025 TSI-mc <surinder.kumar@t-systems.com>
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
*/
package com.owncloud.android.ui.fragment;
Expand Down Expand Up @@ -331,7 +332,7 @@ private void fetchAndSetData(int lastGiven) {
} else {
Log_OC.d(TAG, result.getLogMessage());
// show error
String logMessage = result.getLogMessage();
String logMessage = result.getLogMessage(requireContext());
if (result.getHttpCode() == HttpStatus.SC_NOT_MODIFIED) {
logMessage = getString(R.string.activities_no_results_message);
}
Expand Down
Loading