Return a map of the headers in the options with keys stripped of the "x-bz-info-" prefix
(options []fs.OpenOption)
| 188 | |
| 189 | // Return a map of the headers in the options with keys stripped of the "x-bz-info-" prefix |
| 190 | func OpenOptionToMetaData(options []fs.OpenOption) map[string]string { |
| 191 | var headers = make(map[string]string) |
| 192 | for _, option := range options { |
| 193 | k, v := option.Header() |
| 194 | k = strings.ToLower(k) |
| 195 | if strings.HasPrefix(k, headerPrefix) { |
| 196 | headers[k[len(headerPrefix):]] = v |
| 197 | } |
| 198 | } |
| 199 | |
| 200 | return headers |
| 201 | } |
| 202 | |
| 203 | func (f *Fs) internalTestMetadata(t *testing.T, size string, uploadCutoff string, chunkSize string) { |
| 204 | what := fmt.Sprintf("Size%s/UploadCutoff%s/ChunkSize%s", size, uploadCutoff, chunkSize) |
no test coverage detected
searching dependent graphs…