Fix script to accept hyphens