def METHOD_NAME(db):
    """Return a callable which let you create room attributes."""
    def _create_attribute(name):
        attr = RoomAttribute(name=name, title=name)
        db.session.add(attr)
        db.session.flush()
        return attr
    return _create_attribute