Closes #470

@allpsiritseve Ready for review!