add $unique scope to named function whose name match asked key