Fixes error where content undefined if file does not exist yet