Custom Post Type Pagination Problem in Admin Section

It turns out that in my functions.php file, I had the following function:

function limit_posts_per_archive_page() {
    if ( is_tax('project_categories') )
        $limit = 9999;
    else
        $limit = get_option('posts_per_page');
        set_query_var('posts_per_archive_page', $limit);
    }
add_filter('pre_get_posts', 'limit_posts_per_archive_page');

This was an old function modifying the pagination on the front-end, and it turns out that this was causing the error.

Removing the function fixed this.