resource-watch/document-adapter

View on GitHub
app/src/serializers/fieldSerializer.js

Summary

Maintainability
A
0 mins
Test Coverage
C
75%
class FieldSerializer {

    static serialize(data, tableName) {
        if (!data) {
            return {};
        }

        return {
            tableName,
            fields: data
        };
    }

}

module.exports = FieldSerializer;