only allow classes up to 127
diff --git a/src/main/java/de/ids_mannheim/korap/query/serialize/PoliqarpPlusTree.java b/src/main/java/de/ids_mannheim/korap/query/serialize/PoliqarpPlusTree.java
index f97bd4e..c0c175f 100644
--- a/src/main/java/de/ids_mannheim/korap/query/serialize/PoliqarpPlusTree.java
+++ b/src/main/java/de/ids_mannheim/korap/query/serialize/PoliqarpPlusTree.java
@@ -308,9 +308,11 @@
 					log.error(msg);
 					throw new QueryException(msg);
 				}
-				// only allow class id up to 255
-				if (classId > 255) {
-					classId = 1;
+				// only allow class id up to 127
+				if (classId > 127) {
+					warnings.add("Only class IDs up to 127 are allowed. Your class "+classId+" has been set back to 127. "
+							+ "Check for possible conflict with other classes.");
+					classId = 127;
 				}
 			}
 			LinkedHashMap<String, Object> classGroup = makeSpanClass(classId, false);