got to read from file properly with closures