anchor.diff:    send(ChannelOut, TriggerExchange,Msg),
     send_messages(TriggerExchange,ChannelOut,Rest).
   
  -send_to_output(TriggerId, {Value, Timestamp, StreamId, Input, []}) ->
  +
  +send_to_output(TriggerId, {Value, Timestamp, StreamId, [], []}) ->
       ok;
  -send_to_output(TriggerId, {Value, Timestamp, StreamId, Input, [{user,UserId}|Rest]}) ->
  -    Message = lib_json:set_attrs([
  -        {trigger, "{}"},
  +send_to_output(TriggerId, {Value, Timestamp, StreamId, [Input|Rest], []}) ->
  +    send_to_output(TriggerId, {Value, Timestamp, StreamId, Rest, []});
  +send_to_output(TriggerId, {Value, Timestamp, StreamId, [Input|Inputs], [{user,UserId}|Rest]}) ->
  +    Message = lib_json:set_attrs([{trigger, "{}"},
           {"trigger.value", Value},
           {"trigger.timestamp", Timestamp},
           {"trigger.stream_id", StreamId},
  
positive.code: 
  
  
  
  
  
  
  %% @doc
  %% Function: apply_function()/3
  %% Purpose: Applies the specified predefined function
  
negative.code:             ok;
          {ok, {{_, Code, _}, _, Body}} ->
              {error, {Code, Body}}
      end,
      send_to_output(TriggerId, {Value, Timestamp, StreamId, [Input|Inputs], Rest}).
  send_to_output(TriggerId, {Value, Timestamp, StreamId, [Input|Inputs], [_|Rest]}) ->
      erlang:display("Invalid output!"),
      send_to_output(TriggerId, {Value, Timestamp, StreamId, [Input|Inputs], Rest}).
                
  
  handle_command({add,{Input,User}},[]) ->
  