def db_convert_to_capped(db, coll_name, sizeBytes=2 ** 30):
    """converts a collection to capped"""
    if coll_name in db.collection_names():
        return db.command({'convertToCapped': coll_name, 'size': sizeBytes})
