Change name again to describe the high availability aspect of the function
Fix indents
Tidy up code