Throw an error on empty arguments

Fixes #290
This commit is contained in:
JustAnotherArchivist
2021-10-10 17:43:27 +00:00
parent 5e829e2541
commit a6b6f3faaa
8 changed files with 25 additions and 11 deletions

View File

@@ -139,7 +139,7 @@ class WeiboUserScraper(snscrape.base.Scraper):
@classmethod
def setup_parser(cls, subparser):
subparser.add_argument('user', help = 'A user name or ID')
subparser.add_argument('user', type = snscrape.base.nonempty_string('user'), help = 'A user name or ID')
@classmethod
def from_args(cls, args):