def count_likes(db, filename):
    """Count the number of likes for this filename"""
    flowTowCursor = db.cursor()
    flowTowCursor.execute("SELECT COUNT(*) FROM likes WHERE filename=?", [filename])
    return flowTowCursor.fetchone()[0]