refactoring the rake task to deal with nil values coming from the econest API