Inline some variables
There is no point in `Type a = …; return a;`
This commit is contained in:
@@ -281,9 +281,8 @@ public class TransferStatus {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
String builder = "TransferStatus-" + hashCode() + " [player: " + player.getId() + ", file: " +
|
return "TransferStatus-" + hashCode() + " [player: " + player.getId() + ", file: " +
|
||||||
file + ", terminated: " + terminated + ", active: " + active + "]";
|
file + ", terminated: " + terminated + ", active: " + active + "]";
|
||||||
return builder;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+1
-2
@@ -31,8 +31,7 @@ public class XspfPlaylistExportHandler implements PlaylistExportHandler {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public SpecificPlaylist handle(int id, SpecificPlaylistProvider provider) throws Exception {
|
public SpecificPlaylist handle(int id, SpecificPlaylistProvider provider) throws Exception {
|
||||||
chameleon.playlist.xspf.Playlist playlist = createXsfpPlaylistFromDBId(id);
|
return createXsfpPlaylistFromDBId(id);
|
||||||
return playlist;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
chameleon.playlist.xspf.Playlist createXsfpPlaylistFromDBId(int id) {
|
chameleon.playlist.xspf.Playlist createXsfpPlaylistFromDBId(int id) {
|
||||||
|
|||||||
+1
-2
@@ -56,8 +56,7 @@ public class PlaylistUpnpProcessor extends UpnpContentProcessor <Playlist, Media
|
|||||||
}
|
}
|
||||||
|
|
||||||
public List<Playlist> getAllItems() {
|
public List<Playlist> getAllItems() {
|
||||||
List<Playlist> playlists = getPlaylistService().getAllPlaylists();
|
return getPlaylistService().getAllPlaylists();
|
||||||
return playlists;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public Playlist getItemById(String id) throws Exception {
|
public Playlist getItemById(String id) throws Exception {
|
||||||
|
|||||||
@@ -79,11 +79,9 @@ public class TestCaseUtils {
|
|||||||
"from information_schema.system_tables " +
|
"from information_schema.system_tables " +
|
||||||
"where table_name not like 'SYSTEM%'"
|
"where table_name not like 'SYSTEM%'"
|
||||||
, String.class);
|
, String.class);
|
||||||
Map<String, Integer> nbRecords =
|
|
||||||
tableNames.stream()
|
|
||||||
.collect(Collectors.toMap(table -> table, table -> recordsInTable(table,daoHelper)));
|
|
||||||
|
|
||||||
return nbRecords;
|
return tableNames.stream()
|
||||||
|
.collect(Collectors.toMap(table -> table, table -> recordsInTable(table,daoHelper)));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -12,8 +12,7 @@ public class MusicFolderTestData {
|
|||||||
private static String baseResources = "/MEDIAS/";
|
private static String baseResources = "/MEDIAS/";
|
||||||
|
|
||||||
public static String resolveBaseMediaPath() {
|
public static String resolveBaseMediaPath() {
|
||||||
String baseDir = MusicFolderTestData.class.getResource(baseResources).toString().replace("file:","");
|
return MusicFolderTestData.class.getResource(baseResources).toString().replace("file:","");
|
||||||
return baseDir;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String resolveMusicFolderPath() {
|
public static String resolveMusicFolderPath() {
|
||||||
|
|||||||
Reference in New Issue
Block a user