Support different hash types

please make this an optional argument aswell