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 @@ -133,17 +133,19 @@ extension SwiftPackageTool {
133
133
dryRun: dryRun
134
134
)
135
135
136
- if let pinsStore = swiftTool. diagnostics. wrap ( { try workspace. pinsStore. load ( ) } ) , let changes = changes, dryRun {
137
- logPackageChanges ( changes: changes, pins: pinsStore)
138
- }
139
-
140
- if !dryRun {
141
- // try to load the graph which will emit any errors
136
+ // try to load the graph which will emit any errors
137
+ if !swiftTool. diagnostics. hasErrors {
142
138
_ = try workspace. loadPackageGraph (
143
139
rootInput: swiftTool. getWorkspaceRoot ( ) ,
144
140
diagnostics: swiftTool. diagnostics
145
141
)
142
+ }
146
143
144
+ if let pinsStore = swiftTool. diagnostics. wrap ( { try workspace. pinsStore. load ( ) } ) , let changes = changes, dryRun {
145
+ logPackageChanges ( changes: changes, pins: pinsStore)
146
+ }
147
+
148
+ if !dryRun {
147
149
// Throw if there were errors when loading the graph.
148
150
// The actual errors will be printed before exiting.
149
151
guard !swiftTool. diagnostics. hasErrors else {
You can’t perform that action at this time.
0 commit comments