diff options
author | Henry Wilson <m3henry@googlemail.com> | 2019-02-12 22:59:12 +0000 |
---|---|---|
committer | PeterN <peter@fuzzle.org> | 2019-03-26 20:15:57 +0000 |
commit | 5795f66d2eebccbc8e04b80ebaf163f636479f9e (patch) | |
tree | 53bedfa6e40953f7aaeba3f7c2648e0839aef354 /src/vehicle_cmd.cpp | |
parent | b1f5119d3af2fb47a2f1c752d61a742f41076451 (diff) | |
download | openttd-5795f66d2eebccbc8e04b80ebaf163f636479f9e.tar.xz |
Codechange: Replaced SmallVector::Contains() with std::find() pattern
Diffstat (limited to 'src/vehicle_cmd.cpp')
-rw-r--r-- | src/vehicle_cmd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vehicle_cmd.cpp b/src/vehicle_cmd.cpp index ccc9446a0..636aadb49 100644 --- a/src/vehicle_cmd.cpp +++ b/src/vehicle_cmd.cpp @@ -355,7 +355,7 @@ static CommandCost RefitVehicle(Vehicle *v, bool only_this, uint8 num_vehicles, /* Reset actual_subtype for every new vehicle */ if (!v->IsArticulatedPart()) actual_subtype = new_subtype; - if (v->type == VEH_TRAIN && !vehicles_to_refit.Contains(v->index) && !only_this) continue; + if (v->type == VEH_TRAIN && std::find(vehicles_to_refit.begin(), vehicles_to_refit.end(), v->index) == vehicles_to_refit.end() && !only_this) continue; const Engine *e = v->GetEngine(); if (!e->CanCarryCargo()) continue; |