def login(username=None, password=None): """A shortcut for user login. Create a :class:`.Geocaching` instance and try to login a user. See :meth:`.Geocaching.login`. :return: Created :class:`.Geocaching` instance. """ g = Geocaching() g.login(username, password) return g
def geocaching_logged_in(betamax_session: requests.Session): gc = Geocaching(session=betamax_session) gc.login(USERNAME, PASSWORD) return gc
def login(username, password): """Logs the user in. A shortcut for Geocaching().login().""" g = Geocaching() g.login(username, password) return g