Skip to content

Commit

Permalink
Improve mix operator error message
Browse files Browse the repository at this point in the history
  • Loading branch information
pditommaso committed Jul 17, 2020
1 parent 3b4b377 commit 8074d71
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1104,7 +1104,8 @@ class OperatorEx implements DelegatingPlugin {
* @return
*/
DataflowWriteChannel mix( DataflowReadChannel source, DataflowReadChannel[] others ) {
assert others.size()>0
if( others.size()==0 )
throw new IllegalArgumentException("Operator 'mix' should have at least one right operand")

def target = CH.create()
def count = new AtomicInteger( others.size()+1 )
Expand Down

0 comments on commit 8074d71

Please sign in to comment.