codacy: introduce constant

Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
This commit is contained in:
Andy Scherzinger 2021-02-19 14:09:08 +01:00
parent ac33333c35
commit 06b581a7a9
No known key found for this signature in database
GPG key ID: 6CADC7E3523C308B

View file

@ -81,6 +81,7 @@ public class ChooseRichDocumentsTemplateDialogFragment extends DialogFragment im
private static final String ARG_TYPE = "TYPE";
private static final String TAG = ChooseRichDocumentsTemplateDialogFragment.class.getSimpleName();
private static final String DOT = ".";
public static final int SINGLE_TEMPLATE = 1;
private RichDocumentsTemplateAdapter adapter;
private OCFile parentFolder;
@ -361,7 +362,7 @@ public class ChooseRichDocumentsTemplateDialogFragment extends DialogFragment im
if (templateList.isEmpty()) {
DisplayUtils.showSnackMessage(fragment.binding.list, R.string.error_retrieving_templates);
} else {
if (templateList.size() == 1) {
if (templateList.size() == SINGLE_TEMPLATE) {
fragment.onTemplateChosen(templateList.get(0));
fragment.binding.list.setVisibility(View.GONE);
} else {