code: def check_directory(placeholders):
      
      feed = placeholders.feed
      args = feed.args
      placeholders.directory = "This very directory"  # wink, wink
      placeholders.fullpath = os.path.join(
          placeholders.directory, placeholders.filename)
      try:
          if args["downloaddirectory"]:
              ensure_dir(args["downloaddirectory"])
              placeholders.directory = args["downloaddirectory"]
      except KeyError:
          pass
      download_path = os.path.expanduser(
          feed.retrieve_config("Download Directory", "~/Podcasts"))
      subdirectory = feed.retrieve_config(
          "Create subdirectory", "no")
      if "no" in subdirectory:
          placeholders.directory = download_path
      elif "yes" in subdirectory:
          subdnametemplate = feed.retrieve_config(
              "subdirectory_name", "{podcasttitle}")
          subdname = substitute_placeholders(
              subdnametemplate, placeholders)
          placeholders.directory = os.path.join(download_path, subdname)
      ensure_dir(placeholders.directory)
      placeholders.fullpath = os.path.join(
          placeholders.directory, placeholders.filename)
      return placeholders
docs: Find out, and create if needed,
      the directory in which the feed will be downloaded