Skip to content

Commit a10b77e

Browse files
committed
Adds Location if not present, from geolocation metadata
1 parent 3c163dc commit a10b77e

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

app/main.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ async function inbox (dataArray) {
6666
const chatID = data.ChatID;
6767
if (chatID) delete data.ChatID;
6868

69+
if ('geolocation' in el && ! ('Location' in data)) data.Location = el.geolocation;
70+
6971
data.Received = new Date(el.time*1000).toLocaleString('en-in');
7072

7173
const keysArray = Object.keys(data).sort();

0 commit comments

Comments
 (0)