started using john's types and adding helper methods