Working get_file method