Fixes for some issues I noticed in delayed_jobs