slightly more robust kernel loading via XHR
fixed indentation, no code changes