fix(nsis): prefix StrReplaceAll with un. for uninstall section#119
Conversation
NSIS requires functions called from an Uninstall section to be defined as Function un.FunctionName. StrReplaceAll is only called from the Uninstall section, so rename it to un.StrReplaceAll and update both call sites. StrContains is only called from the Install section and stays unprefixed.
|
Warning Rate limit exceeded
To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📝 WalkthroughWalkthroughThe Windows installer script's uninstaller section now calls a prefixed helper function ChangesUninstaller PATH Cleanup Refactoring
Estimated Code Review Effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Review rate limit: 0/1 reviews remaining, refill in 55 minutes and 16 seconds.Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Problem
`makensis` aborted with:
```
Call must be used with function names starting with "un." in the uninstall section.
Usage: Call function_name | [:label_name]
Error in script "installer.nsi" on line 115 -- aborting creation process
```
NSIS enforces that any function called from an `Uninstall` section must be defined as `Function un.FunctionName` and called as `Call un.FunctionName`. `StrReplaceAll` was defined as a plain `Function` but called from the `Uninstall` section.
Fix
Rename `Function StrReplaceAll` → `Function un.StrReplaceAll` and update both `Call` sites in the uninstall section.
`StrContains` is only called from the install section and stays unprefixed.
Summary by CodeRabbit