Planning for massive Corby warehouse did not comply with the law