From ac499898e365534fea47604d0b6e52f177582bce Mon Sep 17 00:00:00 2001 From: Liam Date: Wed, 3 Jul 2024 00:23:46 +0100 Subject: [PATCH] fix --- .../cc/fascinated/bat/config/MongoConfig.java | 23 ------------------- .../cc/fascinated/bat/model/BatGuild.java | 1 - .../java/cc/fascinated/bat/model/BatUser.java | 1 - 3 files changed, 25 deletions(-) delete mode 100644 src/main/java/cc/fascinated/bat/config/MongoConfig.java diff --git a/src/main/java/cc/fascinated/bat/config/MongoConfig.java b/src/main/java/cc/fascinated/bat/config/MongoConfig.java deleted file mode 100644 index d9f7d5c..0000000 --- a/src/main/java/cc/fascinated/bat/config/MongoConfig.java +++ /dev/null @@ -1,23 +0,0 @@ -package cc.fascinated.bat.config; - -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.Configuration; -import org.springframework.data.mongodb.MongoDatabaseFactory; -import org.springframework.data.mongodb.core.convert.DbRefResolver; -import org.springframework.data.mongodb.core.convert.DefaultDbRefResolver; -import org.springframework.data.mongodb.core.convert.MappingMongoConverter; -import org.springframework.data.mongodb.core.mapping.MongoMappingContext; - -/** - * @author Fascinated (fascinated7) - */ -@Configuration -public class MongoConfig { - @Bean - public MappingMongoConverter mongoConverter(MongoDatabaseFactory mongoFactory, MongoMappingContext mongoMappingContext) { - DbRefResolver dbRefResolver = new DefaultDbRefResolver(mongoFactory); - MappingMongoConverter mongoConverter = new MappingMongoConverter(dbRefResolver, mongoMappingContext); - mongoConverter.setMapKeyDotReplacement("-DOT"); - return mongoConverter; - } -} \ No newline at end of file diff --git a/src/main/java/cc/fascinated/bat/model/BatGuild.java b/src/main/java/cc/fascinated/bat/model/BatGuild.java index 26ebe8f..e361aa8 100644 --- a/src/main/java/cc/fascinated/bat/model/BatGuild.java +++ b/src/main/java/cc/fascinated/bat/model/BatGuild.java @@ -30,7 +30,6 @@ import java.util.Map; */ @Getter @Setter -@Document(collection = "guilds") public class BatGuild extends ProfileHolder { private static final Logger log = LoggerFactory.getLogger(BatGuild.class); /** diff --git a/src/main/java/cc/fascinated/bat/model/BatUser.java b/src/main/java/cc/fascinated/bat/model/BatUser.java index 9ae3118..56ac724 100644 --- a/src/main/java/cc/fascinated/bat/model/BatUser.java +++ b/src/main/java/cc/fascinated/bat/model/BatUser.java @@ -28,7 +28,6 @@ import java.util.Map; @RequiredArgsConstructor @Getter @Setter -@Document(collection = "users") public class BatUser extends ProfileHolder { private static final Logger log = LoggerFactory.getLogger(BatUser.class); /**