595-77 & 595-81

PLEASE read comments for issue 77 on the agile board before QA'ing or
code reviewing my code.