like in your first PR, I would suggest checking for existance of the script as early as possible.