update how files are handled, as I don't get this files object :(