From e067fd9ad6d53bc3b02833125b582b9126402a4d Mon Sep 17 00:00:00 2001 From: Anjandev Momi Date: Sat, 5 Dec 2020 23:16:59 -0500 Subject: [PATCH] Revert "simplify code to get phone number for incoming calls" This reverts commit b0bb9ac9fc251b2463924869ab9dd2cee6317506. This fixes the issue with modemlog having filled with extra mmcli output --- scripts/modem/sxmo_modemmonitor.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/modem/sxmo_modemmonitor.sh b/scripts/modem/sxmo_modemmonitor.sh index a2825ae..ae001bd 100755 --- a/scripts/modem/sxmo_modemmonitor.sh +++ b/scripts/modem/sxmo_modemmonitor.sh @@ -22,7 +22,9 @@ modem_n() { lookupnumberfromcallid() { VOICECALLID=$1 mmcli -m "$(modem_n)" --voice-list-calls -o "$VOICECALLID" -K | - sed -E 's/^call\.properties\.number\s+:\s+//' + grep call.properties.number | + cut -d ':' -f 2 | + tr -d ' ' } checkformissedcalls() {