$msg_recv, 'msg_rejected' => $msg_rejected, 'msg_relay' => $msg_relay, 'msg_sent' => $msg_sent, 'msg_waiting' => $msg_waiting, 'spam' => $spam, 'virus' => $virus, ); $tags = compact('name', 'app_id', 'rrd_name', 'rrd_def'); data_update($device, 'app', $tags, $fields);