Fixing parameters in #hash

This just assigns progress to callback if callback is not already provided. This is a simple fix, with backwards compatibility.