src/main/java/me/dirolgaming/safebac/MetricsLite.java
/**
     * Reads the first line of the file.
     *
     * @param file The file to read. Cannot be null.
     * @return The first line of the file or <code>null</code> if the file does not exist or is empty.
     * @throws IOException If something did not work :(
     */
Reads the first line of the file.
@param file The file to read. Cannot be null.
@return The first line of the file or null if the file does not exist or is empty.
@throws IOException If something did not work :(
Reads the first line of the file . @param file The file to read . Cannot be null . @return The first line of the file or null if the file does not exist or is empty . @throws IOException If something did not work : (
private String readFile(File file) throws IOException {
        if (!file.exists()) {
            return null;
        }
        try (
                FileReader fileReader = new FileReader(file);
                BufferedReader bufferedReader =  new BufferedReader(fileReader)
        ) {
            return bufferedReader.readLine();
        }
    }
private String readFile ( File file ) throws IOException { if ( ! file . exists ( ) ) { return null ; } try ( FileReader fileReader = new FileReader ( file ) ; BufferedReader bufferedReader = new BufferedReader ( fileReader ) ) { return bufferedReader . readLine ( ) ; } }
Reads the first line of the file.
Reads the first line of the file .