From 42d5ab9de82c3b92b6c58e857e35c4696d190b1c Mon Sep 17 00:00:00 2001 From: Matt Harris Date: Sat, 14 Mar 2015 23:28:25 -0700 Subject: [PATCH] Tweak UPS delivery estimate code --- lib/package.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/package.js b/lib/package.js index 11efba9..3bdaf1b 100644 --- a/lib/package.js +++ b/lib/package.js @@ -73,7 +73,11 @@ module.exports = { return "Delivered." } } catch(e) { - return "Delivery date unavailable
" + e.message; + try { + return package.lastResponse.Shipment.ScheduledDeliveryDate; + } catch(e) { + return "Delivery date unavailable
" + e.message; + } } break; case "fedex":