fix bug for sonar