If we have a StorePath and no Outputs, we need to convert to the new format. Note: non-empty Outputs may have StorePath alongside it for backwards-compatibility but we should ignore that legacy StorePath.
()
| 120 | // Note: non-empty Outputs may have StorePath alongside it for backwards-compatibility |
| 121 | // but we should ignore that legacy StorePath. |
| 122 | func (i *SystemInfo) addOutputFromLegacyStorePath() { |
| 123 | if i.StorePath != "" && len(i.Outputs) == 0 { |
| 124 | i.Outputs = []Output{ |
| 125 | { |
| 126 | Default: true, |
| 127 | Name: "out", |
| 128 | Path: i.StorePath, |
| 129 | }, |
| 130 | } |
| 131 | i.outputIsFromStorePath = true |
| 132 | } |
| 133 | } |
| 134 | |
| 135 | // ensurePackagesHaveOutputs is used for backwards-compatibility with the old |
| 136 | // lockfile format where each SystemInfo had a StorePath but no Outputs. |
no outgoing calls
no test coverage detected