URL rewrite add author as base

Alright after some more intensive research and A LOT of errors i got a fix which seems legit.

First of all i keep the rewrite rule in my custom post-type but did change the name:

'rewrite' => array(
    'slug' => '/%designer%/',
),

Then i need to point the %designer% to the correct field (which was in my case a custom field made by ACF. I did this as followed:

add_filter( 'post_type_link', 'art_post_type_link', 10, 4 );

function art_post_type_link( $post_link, $post, $leavename, $sample )
{
    if ( 'art' == $post->post_type ) {
        $designer = get_field( 'designer', $post->ID );
        $post_link = str_replace( '%designer%', $designer['user_nicename'], $post_link );
    }

    return $post_link;
}

Then i needed to make sure the designer/author had his own URL without /author/ base. And that /%author%/%art-name% works. I did this with the following author rewrite.

add_filter( 'author_rewrite_rules', 'no_author_base_rewrite_rules' );

function no_author_base_rewrite_rules( $author_rewrite ) {
    global $wpdb;
    $author_rewrite = array();
    $authors = $wpdb->get_results("SELECT user_nicename AS nicename from $wpdb->users");

    foreach($authors as $author) {
        $author_rewrite["({$author->nicename})/?$"] = 'index.php?author_name=$matches[1]';
        $author_rewrite["({$author->nicename})/([^/]+)/?$"] = 'index.php?post_type=art&name=$matches[2]';
    }

    return $author_rewrite;
}

Then i needed to disable the author_base in the global $wp_rewrite if not in admin:

if( !is_admin() ) {
    add_action('init', 'author_rewrite_base_null');
}

function author_rewrite_base_null() {
    global $wp_rewrite;
    if( 'author' == $wp_rewrite->author_base ) $wp_rewrite->author_base = null;
}

And this did the trick for me, hope it helps someone else.