prey-tracker: extract "patch" to function "prepare"
Add double-quotes around dir variables