Repetitive wordpress PHP styling I was wondering if this was a decent way of handling this function. Please take a look.

// Use Less Mixins from Theme Options to adjust Stylesheets before Parsing Less to CSS
add_filter( 'less_vars', 'wellies_less_vars', 10, 2 );
function wellies_less_vars( $vars, $handle ) {

    //Necessary for UpTheme Framework
    global $up_options;

    //Grab Theme option and check if it's empty and default to color if it is.
    $linkcolor = empty($up_options-&gt;linkcolor) ? '#08c' : $up_options-&gt;linkcolor;
    $linkcolorhover = empty($up_options-&gt;linkcolorhover) ? '#03c' : $up_options-&gt;linkcolorhover;
    $networknavstart = empty($up_options-&gt;networknavstartcolor) ? '#333' :$up_options-&gt;networknavstartcolor;
    $networknavend = empty($up_options-&gt;networknavendcolor) ? '#222' :$up_options-&gt;networknavendcolor;
    $sitenavstart = empty($up_options-&gt;sitenavstartcolor) ? '#333' :$up_options-&gt;sitenavstartcolor;
    $sitenavend = empty($up_options-&gt;sitenavendcolor) ? '#222' :$up_options-&gt;sitenavendcolor;

    //Set Less Mixins to Variables above
    $vars = array(
        'linkColor' =&gt; $linkcolor,
        'linkColorHover' =&gt; $linkcolorhover,
        'networkNavBarStart' =&gt; $networknavstart,
        'networkNavBarEnd' =&gt; $networknavend,
        'siteNavBarStart' =&gt; $sitenavstart,
        'siteNavBarEnd' =&gt; $sitenavend,
    );
    return $vars;
}
//Enqueue Stylesheets if not on dashboard.
function wellies_css_loader() {
    if ( ! is_admin() )
        wp_enqueue_style('bootstrap', get_bloginfo('template_directory').'/library/css/lib/bootstrap.less',  array(), '', 'screen, projection');
    wp_enqueue_style('themes', get_bloginfo('template_directory').'/library/css/theme.less', array(), '', 'screen, projection');
}
add_action('wp', 'wellies_css_loader');


It is currently working but I don't want to have it slow down the site if I can optimize it somehow.
No, this can be written a lot easier.  There is no need to create variables when you are not going to vary the value.  It actually only makes things harder to read.  Assuming you are using PHP 5.3+ consider this:

// It is odd that you aren't using $vars in your method.
// I'll ignore that for now.
function wellies_less_vars( $vars, $handle ) {

    //Necessary for UpTheme Framework
    // This is not nice, but I'll ignore that too. 
    global $up_options;

    //Set Less Mixins to Variables above
    // Grab Theme option and check if it's set and use that, otherwise use a
    // default value.
    // Now there is beauty in the alignment IMO.
    return array(
        'linkColor'          =&gt; $up_options-&gt;linkcolor            ?: '#08c',
        'linkColorHover'     =&gt; $up_options-&gt;linkcolorhover       ?: '#03c',
        'networkNavBarStart' =&gt; $up_options-&gt;networknavstartcolor ?: '#333',
        'networkNavBarEnd'   =&gt; $up_options-&gt;networknavendcolor   ?: '#222',
        'siteNavBarStart'    =&gt; $up_options-&gt;sitenavstartcolor    ?: '#333',
        'siteNavBarEnd'      =&gt; $up_options-&gt;sitenavendcolor      ?: '#222');
}


There is a small difference in functionality, but a large difference in readability.  The ?: uses the value on the left if it evaluates to true (generally a set variable except false), or the value on the right if it is not.