diff --git a/src/modules/Yp/module.pmod.in b/src/modules/Yp/module.pmod.in
index b33c66d40bde7a3fc928db4ddb42e88b423110e1..e22d1d9067c3e79f733d477055ac52eb382f2362 100644
--- a/src/modules/Yp/module.pmod.in
+++ b/src/modules/Yp/module.pmod.in
@@ -1,5 +1,5 @@
 /*
- * $Id: module.pmod.in,v 1.8 1997/06/10 20:31:04 grubba Exp $
+ * $Id: module.pmod.in,v 1.9 1999/08/25 05:07:57 hubbe Exp $
  *
  * YP (NIS) Functionality for Pike
  *
@@ -8,6 +8,8 @@
 
 inherit @module@;
 
+#if constant(@module@.Domain)
+
 // Usual nicknames
 constant nicknames = ([
   "passwd":"passwd.byname",
@@ -93,3 +95,5 @@ class Map {
     }
   }
 };
+
+#endif
\ No newline at end of file