Fixed logic in the beanstalkd provider.