Replace addAlls with parametrized constructor calls

This commit is contained in:
TacoTheDank 2020-05-29 14:50:13 -04:00
parent 62ca1dfccc
commit 71373d055d
3 changed files with 4 additions and 6 deletions

View File

@ -345,8 +345,7 @@ public class DBWriterTest {
}
List<FeedItem> queue = new ArrayList<>();
queue.addAll(feed.getItems());
List<FeedItem> queue = new ArrayList<>(feed.getItems());
adapter.open();
adapter.setQueue(queue);

View File

@ -608,9 +608,8 @@ public class OnlineFeedViewActivity extends AppCompatActivity {
}
final List<String> titles = new ArrayList<>();
final List<String> urls = new ArrayList<>();
urls.addAll(urlsMap.keySet());
final List<String> urls = new ArrayList<>(urlsMap.keySet());
for (String url : urls) {
titles.add(urlsMap.get(url));
}

View File

@ -154,8 +154,8 @@ public class AntennapodHttpClient {
// workaround for Android 4.x for certain web sites.
// see: https://github.com/square/okhttp/issues/4053#issuecomment-402579554
List<CipherSuite> cipherSuites = new ArrayList<>();
cipherSuites.addAll(ConnectionSpec.MODERN_TLS.cipherSuites());
List<CipherSuite> cipherSuites = new ArrayList<>(
ConnectionSpec.MODERN_TLS.cipherSuites());
cipherSuites.add(CipherSuite.TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA);
cipherSuites.add(CipherSuite.TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA);