Compare commits
No commits in common. "main" and "main" have entirely different histories.
3 changed files with 2 additions and 14 deletions
|
@ -1,10 +1,3 @@
|
|||
# REPO MOVED!
|
||||
|
||||
Hey,
|
||||
|
||||
The development for this repository moved to [source.mapcomplete.org](https://source.mapcomplete.org/MapComplete/MastodonBot)
|
||||
Pull requests, issues, ... are welcome there
|
||||
|
||||
# Mastodon-Bot
|
||||
|
||||
This is a bot which is built to post a daily message about mapcomplete-usage.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "mastodon-bot",
|
||||
"version": "0.0.5",
|
||||
"version": "0.0.4",
|
||||
"author": "Pietervdvn",
|
||||
"license": "GPL",
|
||||
"description": "Experimenting with mastodon-bot",
|
||||
|
|
|
@ -68,12 +68,7 @@ export default class OsmUserInfo {
|
|||
return undefined
|
||||
}
|
||||
|
||||
let mastodonlink = mastodonLinks[0]
|
||||
while(mastodonlink.endsWith("/")){
|
||||
mastodonlink = mastodonlink.substring(0, mastodonlink.length - 1)
|
||||
}
|
||||
|
||||
const url = new URL(mastodonlink)
|
||||
const url = new URL(mastodonLinks[0])
|
||||
const username = url.pathname.split("/").at(-1) + (url.host === mastodonApi.hostname ? "" : "@" + url.host)
|
||||
|
||||
if (await mastodonApi.hasNoBot(username)) {
|
||||
|
|
Loading…
Reference in a new issue