Skip to content

Commit

Permalink
fix code analytics
Browse files Browse the repository at this point in the history
Signed-off-by: alperozturk <[email protected]>
  • Loading branch information
alperozturk96 committed Feb 10, 2025
1 parent 2578eca commit 99725f0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
import com.owncloud.android.ui.activity.ToolbarActivity;
import com.owncloud.android.ui.adapter.CommonOCFileListAdapterInterface;
import com.owncloud.android.ui.adapter.GalleryAdapter;
import com.owncloud.android.ui.asynctasks.GallerySearchTask;
import com.owncloud.android.ui.tasks.GallerySearchTask;
import com.owncloud.android.ui.events.ChangeMenuEvent;

import javax.inject.Inject;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
/*
* Nextcloud - Android Client
*
* SPDX-FileCopyrightText: 2025 Alper Ozturk <[email protected]>
* SPDX-FileCopyrightText: 2019 Tobias Kaminsky <[email protected]>
* SPDX-FileCopyrightText: 2019 Nextcloud GmbH
* SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only
* SPDX-FileCopyrightText: 2025 Your Name <[email protected]>
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
package com.owncloud.android.ui.asynctasks
package com.owncloud.android.ui.tasks

import android.content.Context
import androidx.lifecycle.lifecycleScope
Expand Down Expand Up @@ -36,7 +34,7 @@ class GallerySearchTask(
private val photoFragmentWeakReference = WeakReference(photoFragment)
private val tag = "GallerySearchTask"

@Suppress("DEPRECATION", "MagicNumber")
@Suppress("DEPRECATION")
fun execute(endDate: Long, limit: Int) {
val photoFragment = photoFragmentWeakReference.get() ?: return
photoFragment.lifecycleScope.launch(Dispatchers.IO) {
Expand All @@ -51,7 +49,8 @@ class GallerySearchTask(
setLimit(limit)
setEndDate(endDate)

// workaround to keep SearchRemoteOperation functioning correctly even if we don't actively use startDate
// workaround to keep SearchRemoteOperation
// functioning correctly even if we don't actively use startDate
setStartDate(0L)
this
}
Expand Down Expand Up @@ -81,6 +80,7 @@ class GallerySearchTask(
}
}

@Suppress("MagicNumber")
private fun logGallerySearch(endDate: Long, limit: Int) {
if (!BuildConfig.DEBUG) {
return
Expand Down

0 comments on commit 99725f0

Please sign in to comment.