Removing use of BufferedReader