airbyte-connectors
airbyte-connectors copied to clipboard
Fix in 'buildPipeline' function
Description
This pull request fixes a bug in the buildPipeline
function. The change made was:
- selector: {type: data.target?.selector.type},
- selector: {type: data.target?.selector?.type},
Type of change
- [x] Bug fix
- [ ] New feature
- [ ] Breaking change
Explanation:
The previous version of the buildPipeline function did not work correctly if the selector field was null or undefined. This happened because the code tried to access the type field of a null object, which resulted in an error.
The change fixes this issue by checking if the selector field exists before accessing the type field. If the selector field is null or undefined, the function will return an empty object.
Benefits:
This fix improves the reliability and robustness of the buildPipeline function. It prevents errors from being thrown if the selector field is null or undefined.
Testing:
I tested this change locally and it works as expected. I created a test case where the selector field was null and the function returned the empty object as expected.
I look forward to your review and approval.
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅
I have read the CLA Document and I hereby sign the CLA
@claudio-mas Thank you for your contribution! We do required signed commits though. Could you please sign your commit? I'll approve then 🙏
Quality Gate passed
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code
@claudio-mas Thank you for your contribution! We do required signed commits though. Could you please sign your commit? I'll approve then 🙏
@ypc-faros I'm not sure if I did it correctly, is there something else missing on my part? Thank you 👍
@claudio-mas Thanks for fixing this! Could you rebase/squash your commits and force-push your branch so that all the commit(s) are signed? The first commit in your branch is still unsigned and therefore blocking us from merging.
@claudio-mas Thanks for fixing this! Could you rebase/squash your commits and force-push your branch so that all the commit(s) are signed? The first commit in your branch is still unsigned and therefore blocking us from merging.
@cjwooo I don't think I'll be able to sign the first commit, could this be resolved by redoing the pull request?
@claudio-mas Apologies for late response, creating a new branch, commit, and PR should resolve it.
Duplicated change with https://github.com/faros-ai/airbyte-connectors/pull/1451