You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: audit.rb
    path of file: ./repos/arachni/lib/arachni/framework/parts
    
    the code of the file until where you have to start completion: =begin
    Copyright 2010-2022 Ecsypno <http://www.ecsypno.com>

    This file is part of the 
    
    def audit_queues
        return if @audit_queues_done == false || !has_audit_workload? ||
            page_limit_reached?

        @audit_queues_done = false

        while !suspended? && !page_limit_reached? && (page = pop_page)

            session.ensure_logged_in

            replenish_page_queue_from_url_queue

            # We're counting on piggybacking the page queue replenishing on the
            # page audit, however if there wasn't an audit we need to force an
            # HTTP run.
            audit_page( page ) or http.run

            handle_signals
        end