Factored the script out