"use strict";

const wrapError = require("@validatem/wrap-error");
const required = require("@validatem/required");
const arrayOf = require("@validatem/array-of");

module.exports = function (operations) {
	const isExpression = require("./is-expression")(operations);
	
	return wrapError("Must be a list of expression objects", [
		arrayOf([ required, isExpression ])
	], { preserveOriginalErrors: true });	
};
