mirror of
https://github.com/Team4388/RidgeScout.git
synced 2026-06-09 00:37:59 -06:00
Fix crash
This commit is contained in:
@@ -97,11 +97,11 @@ public class FTPSync extends Thread {
|
||||
boolean sendMetaFiles = settingsManager.getFTPSendMetaFiles();
|
||||
|
||||
// Meta files
|
||||
String[] meta_string_array = new String[]{
|
||||
List<String> meta_string_array = Arrays.asList(
|
||||
"matches.fields",
|
||||
"pits.fields",
|
||||
evcode+".eventdata"
|
||||
};
|
||||
);
|
||||
|
||||
try {
|
||||
// Login to FTP
|
||||
@@ -123,7 +123,7 @@ public class FTPSync extends Thread {
|
||||
// Remove timestamts file
|
||||
if(localFile.getName().equals(timestampsFilename)) continue;
|
||||
// Remove meta files if the option is disabled
|
||||
if(!sendMetaFiles && Arrays.stream(meta_string_array).anyMatch(localFile.getName()::equals)) continue;
|
||||
if(!sendMetaFiles && meta_string_array.contains(localFile.getName())) continue;
|
||||
|
||||
Date remoteTimestamp = remoteTimestamps.get(localFile.getName());
|
||||
|
||||
|
||||
@@ -97,8 +97,8 @@ public class settingsManager {
|
||||
public static String getFTPServer(){return prefs.getString( FTPServer, (String) defaults.get(FTPServer));}
|
||||
public static void setFTPServer(String str){ getEditor().putString( FTPServer,str).apply();}
|
||||
|
||||
public static boolean getFTPSendMetaFiles(){return prefs.getBoolean(FTPServer, (boolean) defaults.get(FTPServer));}
|
||||
public static void setFTPSendMetaFiles(String str){getEditor().putString(FTPServer,str).apply();}
|
||||
public static boolean getFTPSendMetaFiles(){return prefs.getBoolean(FTPSendMetaFiles, (boolean) defaults.get(FTPSendMetaFiles));}
|
||||
public static void setFTPSendMetaFiles(String str){getEditor().putString(FTPSendMetaFiles,str).apply();}
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user