added ability to pass in block to create job