| 177 | } |
| 178 | |
| 179 | function createChildrenForEmptyPaths( |
| 180 | routes: Route[], |
| 181 | primarySegment: UrlSegmentGroup, |
| 182 | ): {[name: string]: UrlSegmentGroup} { |
| 183 | const res: {[name: string]: UrlSegmentGroup} = {}; |
| 184 | res[PRIMARY_OUTLET] = primarySegment; |
| 185 | |
| 186 | for (const r of routes) { |
| 187 | if (r.path === '' && getOutlet(r) !== PRIMARY_OUTLET) { |
| 188 | const s = new UrlSegmentGroup([], {}); |
| 189 | res[getOutlet(r)] = s; |
| 190 | } |
| 191 | } |
| 192 | return res; |
| 193 | } |
| 194 | |
| 195 | function containsEmptyPathMatchesWithNamedOutlets( |
| 196 | segmentGroup: UrlSegmentGroup, |