<commit_before>export default class MapCtrl {
  constructor($scope, $window, $element, PlatformService, PositionService, RouteService) {
    this.platform = PlatformService.platform;
    this.positionService = PositionService;
    this.routeService = RouteService;

    this.$onInit = () => {
      this.getWindowDimensions = function () {
          return {
              'h': $window.innerHeight,
              'w': $window.innerWidth
          };
      };

      $scope.$on('selected.position.updated', () => {
        let value = this.positionService.getPosition();
        let position = {lat: value.Latitude, lng: value.Longitude};
        this.map.setCenter(position, true);
        this.map.setZoom(10.5, true);
      });

      $scope.$on('route.waypoints.updated', () => {
        this.routeService.calculateRoute((result) => {
          let route,
              routeShape,
              strip;
          if (result.response.route) {
            // Pick the first route from the response:
            route = result.response.route[0];
            // Pick the route's shape:
            routeShape = route.shape;

            // Create a strip to use as a point source for the route line
            strip = new H.geo.Strip();<commit_msg>Fixed an issue with route drawing.<commit_after>export default class MapCtrl {
  constructor($scope, $window, $element, PlatformService, PositionService, RouteService) {
    this.platform = PlatformService.platform;
    this.positionService = PositionService;
    this.routeService = RouteService;

    this.$onInit = () => {
      this.getWindowDimensions = function () {
          return {
              'h': $window.innerHeight,
              'w': $window.innerWidth
          };
      };

      $scope.$on('selected.position.updated', () => {
        let value = this.positionService.getPosition();
        let position = {lat: value.Latitude, lng: value.Longitude};
        this.map.setCenter(position, true);
        this.map.setZoom(10.5, true);
      });

      $scope.$on('route.waypoints.updated', () => {
        this.routeService.calculateRoute((result) => {
          let route,
              routeShape,
              strip;
          if (result.response && result.response.route) {
            this.map.getObjects().forEach(object => this.map.removeObject(object));
            // Pick the first route from the response:
            route = result.response.route[0];
            // Pick the route's shape:
            routeShape = route.shape;

            // Create a strip to use as a point source for the route line
            strip = new H.geo.Strip();
{'fraction_non_alphanumeric': 0.12366412213740458, 'fraction_numerical': 0.0030534351145038168, 'mean_word_length': 2.1054502369668247, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2109342', 'n_tokens_mistral': 696, 'n_tokens_neox': 685, 'n_words': 161}