Skip to content

cmd/gitserver/server: Handle warning error in handleRepoUpdate

Warren Gifford requested to merge ig/use-warning-error into main

Created by: indradhanush

In this commit we start handling a potential warning type error that might be returned from underlying functions. To do this we have to make some minor structural changes to this method:

  • We start returning early at the cost of a little bit of repeated code to JSON encode the response
  • This also has the positive side effect of reducing nesting in the code

Test plan

TODO: Add tests.

Merge request reports

Loading