fix defining aggregate optionjs