Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Angularjs 错误:转换已被其他转换取代_Angularjs_Websocket_Angular Ui Router - Fatal编程技术网

Angularjs 错误:转换已被其他转换取代

Angularjs 错误:转换已被其他转换取代,angularjs,websocket,angular-ui-router,Angularjs,Websocket,Angular Ui Router,我得到了错误,但只是有时: The transition has been superseded by a different transition 我正在使用angular V1.6.9和ui路由器V1.0.16 这是我的密码: var ws = new websocket("ws:/*********") ws.onmessage = function(message) { if(message) { if(message.type=="weather") {

我得到了错误,但只是有时:

The transition has been superseded by a different transition
我正在使用
angular V1.6.9
ui路由器V1.0.16

这是我的密码:

var ws = new websocket("ws:/*********")
ws.onmessage = function(message)
{
  if(message)
  {
    if(message.type=="weather")
    {
      $state.go("Index.weather",{weatherObj:message});
    }
    if(message.type=="temperature")
    {
      $state.go("Index.temperature",{tempObj:message});
    }
    if(message.type=="humidity")
    {
      $state.go("Index.humidity",{humObj:message});
    }
    if(message.type=="rain")
    {
      $state.go("Index.rain",{rainObj:message});
    }
  }
}

请包括错误的整个堆栈跟踪。transitionRejection(类型:2,消息:转换已被其他转换取代,详细信息: