import uuid


def photo_upload_path(note, filename):
    """Function that generates the path and filename of each meal photo uploaded."""
    path = 'notes/'
    path += uuid.uuid4().hex + '_'  # necessary to prevent filename clashes
    path += str(filename)
    return path[:1024]