Centralize segment reference fallback in model
This commit is contained in:
@@ -160,13 +160,7 @@ func (r run) coalescedSegment(id int) model.Segment {
|
||||
}
|
||||
|
||||
func segmentRef(segment model.Segment) string {
|
||||
if segment.SourceSegmentIndex != nil {
|
||||
return fmt.Sprintf("%s#%d", segment.Source, *segment.SourceSegmentIndex)
|
||||
}
|
||||
if segment.SourceRef != "" {
|
||||
return segment.SourceRef
|
||||
}
|
||||
return segment.Source
|
||||
return model.SegmentReference(segment)
|
||||
}
|
||||
|
||||
func isSkippableInterjection(segment model.Segment) bool {
|
||||
|
||||
Reference in New Issue
Block a user