def _is_user_directory(self, pathname):
      """Check whether `pathname` is a valid user data directory

      This method is meant to be called on the contents of the userdata dir.
      As such, it will return True when `pathname` refers to a directory name
      that can be interpreted as a users' userID.
      """
      fullpath = os.path.join(self.userdata_location(), pathname)
      # SteamOS puts a directory named 'anonymous' in the userdata directory
      # by default. Since we assume that pathname is a userID, ignore any name
      # that can't be converted to a number
      return os.path.isdir(fullpath) and pathname.isdigit()
Check whether `pathname` is a valid user data directory

      This method is meant to be called on the contents of the userdata dir.
      As such, it will return True when `pathname` refers to a directory name
      that can be interpreted as a users' userID.