Use defer module for deferreds