Fix exception when running locally