lib.jsView |
---|
11 | 11 | logs.forEach(msg => { |
12 | 12 | uri.withinString(msg.value.content.text, (datLink) => { |
13 | 13 | if (!datLink.startsWith("dat://")) return |
14 | 14 | |
15 | | - console.log("Saving to:", shareFolder + "/" + datLink.substring(6)) |
| 15 | + if (!useTemp) |
| 16 | + console.log("Saving to:", shareFolder + "/" + datLink.substring(6)) |
16 | 17 | |
17 | 18 | Dat(shareFolder + "/" + datLink.substring(6), { |
18 | 19 | key: datLink, |
19 | 20 | temp: useTemp |
30 | 31 | getAll: function(sbot, shareFolder, useTemp) { |
31 | 32 | console.log("Looking for dat links in all feeds") |
32 | 33 | |
33 | 34 | pull( |
34 | | - sbot.createLogStream({ live: true, reverse: true, limit: 10000 }), |
| 35 | + sbot.createLogStream({ reverse: true, limit: 15000 }), |
35 | 36 | pull.filter((msg) => { |
36 | 37 | return !msg.value || |
37 | 38 | msg.value.content.type == 'post' && |
38 | 39 | typeof msg.value.content.text == "string" && |
49 | 50 | shareFolder, useTemp) { |
50 | 51 | console.log("users:", following) |
51 | 52 | console.log("channels:", channelSubscriptions) |
52 | 53 | pull( |
53 | | - sbot.createLogStream({ live: true, reverse: true, limit: 10000 }), |
| 54 | + sbot.createLogStream({ reverse: true, limit: 15000 }), |
54 | 55 | pull.filter((msg) => { |
55 | 56 | return !msg.value || |
56 | 57 | ((msg.value.author in following || |
57 | 58 | msg.value.content.channel in channelSubscriptions) |