pass likes on private messages

This commit is contained in:
qo-op 2020-03-16 01:15:07 +01:00
parent 7e1ee5fd6b
commit 3c86ecfa4f
1 changed files with 7 additions and 0 deletions

View File

@ -114,6 +114,13 @@ normal=$(tput sgr0)
sbotc query.read '{"query":[{"$filter":{"value":{"author":"'"$self"'","content":{"type":"vote", "vote":{"expression":"Like"}},"timestamp":{"$gt":'"$last_ts"'}}}}]}' | while read -r msg
do
priv=$(printf %s "$msg" | jq .value.content.private)
if [[ $priv == true ]]
then
printf "Private message $priv, continue to next one\n" >&2
continue
fi
if ! ts=$(printf %s "$msg" | jq -r .value.timestamp)
then
printf 'Unable to get message timestamp\n' >&2