Skip to content

Commit

Permalink
resolved comment non_positive_allocation_network_id()
Browse files Browse the repository at this point in the history
  • Loading branch information
Jingru923 committed Feb 1, 2024
1 parent 6965280 commit df322b5
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion core/src/create.jl
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ const nonconservative_nodetypes =
function generate_allocation_models!(p::Parameters, config::Config)::Nothing
(; graph, allocation_models) = p

errors = non_positive_id(graph)
errors = non_positive_allocation_network_id(graph)

if errors
error("Allocation network initialization failed.")
Expand Down
2 changes: 1 addition & 1 deletion core/src/validation.jl
Original file line number Diff line number Diff line change
Expand Up @@ -673,7 +673,7 @@ function incomplete_subnetwork(graph::MetaGraph, node_ids::Dict{Int, Set{NodeID}
return errors
end

function non_positive_id(graph::MetaGraph)::Bool
function non_positive_allocation_network_id(graph::MetaGraph)::Bool
errors = false
for allocation_network_id in keys(graph[].node_ids)
if (allocation_network_id <= 0)
Expand Down
2 changes: 1 addition & 1 deletion core/test/create_test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

logger = TestLogger()
with_logger(logger) do
Ribasim.non_positive_id(graph)
Ribasim.non_positive_allocation_network_id(graph)
end

@test length(logger.logs) == 2
Expand Down

0 comments on commit df322b5

Please sign in to comment.