formatted timestamp correctly
This commit is contained in:
parent
f26401ec1f
commit
a899fc0917
|
@ -114,7 +114,7 @@ getcbk_data() {
|
|||
gettimestamp() {
|
||||
local timestamp="$(tail -n 1 "${bot_tmpdir}${1}"\
|
||||
| grep "\"date\"" | grep -om1 "\"date\":[0-9]\+,")"
|
||||
[ ! -z "${timestamp}" ] && printf "%s" "${timestamp:7:-1}"
|
||||
[ ! -z "${timestamp}" ] && date "+%D %H:%M" -d "@${timestamp:7:-1}"
|
||||
}
|
||||
|
||||
# $1 is name of a bash array with the number of columns in every row such as ( 1 1 3 ) for a 3 row keyboard in which the first and second row have 1 column, and the third has 3
|
||||
|
|
Loading…
Reference in New Issue