cleaning up some code and switching RS calls to RS.call()