added dispatch_block support and function chaining