Type determined return values I have the following js code:

if (typeof errorCallback === "function") {
    var result = errorCallback.apply(this, arguments);
    // if errorCallback returns a non-false value, end execution
    if (result) {
        return result;
    }
}

// if there's no errorCallback or errorCallback returned 'false',
// 'null', 'undefined', '', 0, hell-knows-what-else ...
// note, that we don't return anything here
defaultErrorCallback.apply(this, arguments);


So far I came up with this:

return (typeof errorCallback=== "function"
    ? errorCallback.apply(this, arguments)
    : void 0) || defaultErrorCallback.apply(this, arguments);


But this will return (in some cases) the result of defaultErrorCallback whereas I want it to return undefined.

Can this code be shortened without changing functionality?
More of a golf question than a CodeReview question really,

I would first consider

return (c
  ? someFunc.apply(this, arguments) || undefined
  : undefined) 


The interesting part is that if otherFunc is not a function, then you would have executed it as a function anyway.. 
Furthemore,


I like better someFunc instanceof Function than typeof someFunc === "function"
For something this fancy I would go for the Spartan f
I tend to avoid void except for bookmarklets


so perhaps something like this:

//Unless f is a function and returns a non false value, return undefined
return (f instanceof Function ? f.apply(this, arguments) : undefined ) 
       || alternativeFunction.apply(this,arguments );