(filePath, fileEncoding string)
| 1835 | } |
| 1836 | |
| 1837 | func (h *fsHandler) newCompressedFSFile(filePath, fileEncoding string) (*fsFile, error) { |
| 1838 | f, err := h.filesystem.Open(filePath) |
| 1839 | if err != nil { |
| 1840 | return nil, fmt.Errorf("cannot open compressed file %q: %w", filePath, err) |
| 1841 | } |
| 1842 | fileInfo, err := f.Stat() |
| 1843 | if err != nil { |
| 1844 | _ = f.Close() |
| 1845 | return nil, fmt.Errorf("cannot obtain info for compressed file %q: %w", filePath, err) |
| 1846 | } |
| 1847 | return h.newFSFile(f, fileInfo, true, filePath, fileEncoding) |
| 1848 | } |
| 1849 | |
| 1850 | func (h *fsHandler) openFSFile(filePath string, mustCompress bool, fileEncoding string) (*fsFile, error) { |
| 1851 | filePathOriginal := filePath |
no test coverage detected