File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -134,17 +134,19 @@ extension SwiftPackageTool {
134
134
dryRun: dryRun
135
135
)
136
136
137
- if let pinsStore = swiftTool. diagnostics. wrap ( { try workspace. pinsStore. load ( ) } ) , let changes = changes, dryRun {
138
- logPackageChanges ( changes: changes, pins: pinsStore)
139
- }
140
-
141
- if !dryRun {
142
- // try to load the graph which will emit any errors
137
+ // try to load the graph which will emit any errors
138
+ if !swiftTool. diagnostics. hasErrors {
143
139
_ = try workspace. loadPackageGraph (
144
140
rootInput: swiftTool. getWorkspaceRoot ( ) ,
145
141
diagnostics: swiftTool. diagnostics
146
142
)
143
+ }
147
144
145
+ if let pinsStore = swiftTool. diagnostics. wrap ( { try workspace. pinsStore. load ( ) } ) , let changes = changes, dryRun {
146
+ logPackageChanges ( changes: changes, pins: pinsStore)
147
+ }
148
+
149
+ if !dryRun {
148
150
// Throw if there were errors when loading the graph.
149
151
// The actual errors will be printed before exiting.
150
152
guard !swiftTool. diagnostics. hasErrors else {
You can’t perform that action at this time.
0 commit comments