Invalidate cache on upload to avoid bug where if page refreshed fast enough, empty flight was cached; also fix bug with flight index view b/c of uninstantiated functions