instagram: No romperse si no es un reel
This commit is contained in:
parent
2e02b5a7a1
commit
6d33ce97df
1 changed files with 4 additions and 0 deletions
|
@ -3,6 +3,7 @@ package main
|
|||
import (
|
||||
"log"
|
||||
"net/url"
|
||||
"strings"
|
||||
|
||||
"nulo.in/dlbot/common"
|
||||
|
||||
|
@ -13,6 +14,9 @@ func respond(bot *tgbotapi.BotAPI, update tgbotapi.Update, url *url.URL) common.
|
|||
if url.Hostname() != "instagram.com" && url.Hostname() != "www.instagram.com" {
|
||||
return common.NotValid
|
||||
}
|
||||
if strings.Index(url.Path, "/reel/") != 0 {
|
||||
return common.NotValid
|
||||
}
|
||||
|
||||
log.Printf("Downloading %s", url.String())
|
||||
lookup, err := Lookup(url.String())
|
||||
|
|
Reference in a new issue