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: db.go
    path of file: ./repos/go-ibax/packages/block
    
    the code of the file until where you have to start completion: /*---------------------------------------------------------------------------------------------
 *  Copyright (c) IBAX. All rights reserved.
 *  See LICENSE in the project root for license information.
 *------------------------------------------------------------------------------------------
    
func GetRollbacksHashWithDiffArr(dbTx *sqldb.DbTransaction, bId int64) ([]byte, error) {
	rollbackTx := sqldb.RollbackTx{}
	rollbackTxs, err := rollbackTx.GetBlockRollbackTransactions(dbTx, bId)
	if err != nil {
		return nil, err
	}
	arr := make([]string, 0)
	for _, row := range rollbackTxs {
		data, err := json.Marshal(row)
		if err != nil {
			continue
		}
		arr = append(arr, crypto.HashHex(data))
	}
	spentInfos, err := sqldb.GetBlockOutputs(dbTx, bId)
	if err != nil {
		return nil, err
	}
	for _, row := range spentInfos {
		data, err := json.Marshal(row)
		if err != nil {
			continue
		}
		arr = append(arr, crypto.HashHex(data))
	}
	sort.Strings(arr)
	marshal, _ := json.Marshal(arr)
	return crypto.Hash(marshal), nil
}