ScriptValue InspectorDebuggerAgent::resolveCallFrame(ErrorString* errorString, const String* callFrameId)
{
    if (!callFrameId)
        return ScriptValue();
    if (!isPaused() || m_currentCallStack.isNull()) {
        *errorString = "Attempt to access callframe when debugger is not on pause";
        return ScriptValue();
    }
    InjectedScript injectedScript = m_injectedScriptManager->injectedScriptForObjectId(*callFrameId);
    if (injectedScript.hasNoValue()) {
        *errorString = "Inspected frame has gone";
        return ScriptValue();
    }
    return injectedScript.findCallFrameById(errorString, m_currentCallStack, *callFrameId);
}