refactored method signatures slightly