import logging


def sched_uploaded(c, d):
    """
    Checks to see if the schedule has already been processed

    Params:
        c: (psycopg2.extensions.cursor)
        d: (datetime.datetime) containing the date we desire to check

    Returns:
        True if the date "dt" has already been processed, else returns False
    """
    logging.info({'func': 'sched_uploaded',
                  'msg': 'Checking if schedule has been processed'})
    c.execute("SELECT id FROM schedule WHERE date=%s", [d.strftime("%B %-d")])
    return bool(c.fetchone())