Describe the bug
An error is generated, using version 1.9.1, for missing variable $adfi when trying to remove a credential that is no longer in config files.
It appears on line 16 $adfi should be $adfInstance which then generates the error inside of Remove-AdfObject.ps
Exception: /home/runner/.local/share/powershell/Modules/azure.datafactory.tools/1.9.1/private/Remove-AdfObject.ps1:134
Line |
134 | throw $ErrorMessage
| ~~~~~~~~~~~~~~~~~~~
| The variable '$adfi' cannot be retrieved because it has not been set.
Error: Process completed with exit code 1.
To Reproduce
Your script to reproduce the behaviour:
1. Create credential
2. Deploy nothing
3. See error
Expected behaviour
Credential was deleted
Screenshots
If applicable, add screenshots to help explain your problem.
Version of PowerShell module of:
ver 1.9.1
Provide all files to reproduce the issue
Attach at least log file (you can wipe out any potentially sensitive info)
Attach files of objects which are involved in the process
Describe the bug An error is generated, using version 1.9.1, for missing variable $adfi when trying to remove a credential that is no longer in config files.
It appears on line 16 $adfi should be $adfInstance which then generates the error inside of Remove-AdfObject.ps
https://github.com/Azure-Player/azure.datafactory.tools/blob/517d2f0e1c2a8a3aa9e4205845170bde875aed57/private/Remove-AdfObjectRestAPI.ps1#L16
To Reproduce Your script to reproduce the behaviour:
Expected behaviour Credential was deleted
Screenshots If applicable, add screenshots to help explain your problem.
Version of PowerShell module of:
Provide all files to reproduce the issue