When deleting a function version:
- The version should not being used by any job
- The version should not being used by any webhook
- Function latest_version should be updated if the version in request equals
to latest_version
Story: #2001829
Task: #14349
Change-Id: I5511304e04bec8f404d7224a6489b65d6a765316