You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: csv.go
    path of file: ./repos/dasel/storage
    
    the code of the file until where you have to start completion: package storage

import (
	"bytes"
	"encoding/csv"
	"fmt"
	"github.com/tomwright/dasel/v2"
	"github.com/tomwright/dasel/v2/dencoding"
	"github.com/tomwright/dasel/v2/util"
	"sort"
)

func init() {
	registerReadParser([]string{"csv"}, []string{".csv"}, &CSVParser{})
	registerWriteParser([]string{"csv"}, []string{".csv"}, &CSVParser{})
}

// CSVParser is a Parser implementation to handl
    
func (p *CSVParser) FromBytes(byteData []byte, options ...ReadWriteOption) (dasel.Value, error) {
	if byteData == nil {
		return dasel.Value{}, fmt.Errorf("could not read csv file: no data")
	}

	reader := csv.NewReader(bytes.NewBuffer(byteData))

	for _, o := range options {
		switch o.Key {
		case OptionCSVComma:
			if value, ok := o.Value.(rune); ok {
				reader.Comma = value
			}
		case OptionCSVComment:
			if value, ok := o.Value.(rune); ok {
				reader.Comment = value
			}
		}
	}

	res := make([]*dencoding.Map, 0)
	records, err := reader.ReadAll()
	if err != nil {
		return dasel.Value{}, fmt.Errorf("could not read csv file: %w", err)
	}
	if len(records) == 0 {
		return dasel.Value{}, nil
	}
	var headers []string
	for i, row := range records {
		if i == 0 {
			headers = row
			continue
		}
		rowRes := dencoding.NewMap()
		allEmpty := true
		for index, val := range row {
			if val != "" {
				allEmpty = false
			}
			rowRes.Set(headers[index], val)
		}
		if !allEmpty {
			res = append(res, rowRes)
		}
	}

	return dasel.ValueOf(res).
		WithMetadata("csvHeaders", headers), nil
}