@bananapus/core-v6 0.0.67 → 0.0.68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bananapus/core-v6",
3
- "version": "0.0.67",
3
+ "version": "0.0.68",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -183,8 +183,10 @@ library CoreDeploymentLib {
183
183
  {
184
184
  string memory filePath = string.concat(path, projectName, "/", networkName, "/", contractName, ".json");
185
185
  // forge-lint: disable-next-line(unsafe-cheatcode)
186
- if (!vm.exists(filePath)) return address(0);
187
- // forge-lint: disable-next-line(unsafe-cheatcode)
188
- return stdJson.readAddress({json: vm.readFile(filePath), key: ".address"});
186
+ try vm.readFile(filePath) returns (string memory deploymentJson) {
187
+ return stdJson.readAddress({json: deploymentJson, key: ".address"});
188
+ } catch {
189
+ return address(0);
190
+ }
189
191
  }
190
192
  }