diff --git a/lib/modules/Protocols.pmod/SocketIO.pmod b/lib/modules/Protocols.pmod/SocketIO.pmod
index 74c23f28bd522d5743d2a1f9454d1a82280739d0..fbae8017c26983cf284f3f1adee11add6945911a 100644
--- a/lib/modules/Protocols.pmod/SocketIO.pmod
+++ b/lib/modules/Protocols.pmod/SocketIO.pmod
@@ -267,11 +267,12 @@ class Client {
   }
 
   //! Send text or binary events.
-  final void emit(string|function(mixed, mixed ...:void) ack_cb,
-   mixed ... data) {
-    if (!stringp(ack_cb) || !stringp(data[0]))
-      DUSERERROR("Event must be of type string.");
-    write(ack_cb, @data);
+  final variant void emit(function(mixed, mixed ...:void) ack_cb,
+   string event, mixed ... data) {
+    write(ack_cb, event, @data);
+  }
+  final variant void emit(string event, mixed ... data) {
+    write(event, @data);
   }
 
   private void send(int type, void|string|array data,