Serves a single file for displaying it in /show
(ctx context.Context, in *sourcebackendpb.FileRequest)
| 148 | newIndex.Close() |
| 149 | newBase.Close() |
| 150 | return err |
| 151 | } |
| 152 | hidden = make(map[string]bool) |
| 153 | for line := range strings.SplitSeq(string(b), "\n") { |
| 154 | pkg := strings.TrimSpace(line) |
| 155 | if pkg == "" { |
| 156 | continue |
| 157 | } |
| 158 | hidden[pkg] = true |
| 159 | } |
| 160 | } |
| 161 | |
| 162 | s.mu.Lock() |
| 163 | oldIndex := s.index |
| 164 | oldBase := s.base |
| 165 | s.index = newIndex |
| 166 | s.base = newBase |
| 167 | s.hidden = hidden |
| 168 | s.mu.Unlock() |
| 169 |
nothing calls this directly
no outgoing calls
no test coverage detected