aboutsummaryrefslogtreecommitdiff
path: root/src/openvic/map/Province.cpp
diff options
context:
space:
mode:
author Hop311 <hop3114@gmail.com>2023-08-24 01:32:23 +0200
committer Hop311 <hop3114@gmail.com>2023-08-24 01:32:23 +0200
commitefa88c722fcb6c8fea7a86e1b3b8a83f1f59eb31 (patch)
tree0d64199bf4f19fabaaff083b35aa8625823d6c1e /src/openvic/map/Province.cpp
parent6f4a6c77c6f2613e65a403c3a2964d5041a538c7 (diff)
Big Dataloader Commit (openvic-simulation)
Diffstat (limited to 'src/openvic/map/Province.cpp')
-rw-r--r--src/openvic/map/Province.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/openvic/map/Province.cpp b/src/openvic/map/Province.cpp
index 3de7263..76e478f 100644
--- a/src/openvic/map/Province.cpp
+++ b/src/openvic/map/Province.cpp
@@ -65,11 +65,13 @@ std::string Province::to_string() const {
return stream.str();
}
-void Province::add_pop(Pop&& pop) {
- if (is_water()) {
- Logger::error("Trying to add pop to water province ", get_identifier());
- } else {
+return_t Province::add_pop(Pop&& pop) {
+ if (!is_water()) {
pops.push_back(std::move(pop));
+ return SUCCESS;
+ } else {
+ Logger::error("Trying to add pop to water province ", get_identifier());
+ return FAILURE;
}
}