Factor out get_prop function
Easier automation