Fixed usage of a reference in a commit of mine.
According to a comment by mordante in variable.hpp, std::string& foo = vcfg["foo"] is unsafe, and silene appears to have always used config::attribute_value foo = vcfg["foo"] (without reference).
This commit is contained in:
parent
b6426bc0fd
commit
ed3cc61416
1 changed files with 1 additions and 1 deletions
|
@ -814,7 +814,7 @@ WML_HANDLER_FUNCTION(teleport, event_info, cfg)
|
|||
|
||||
const unit* pass_check = NULL;
|
||||
//@deprecated ignore_passability 1.9.10
|
||||
const config::attribute_value& ignore_passability = cfg["ignore_passability"];
|
||||
const config::attribute_value ignore_passability = cfg["ignore_passability"];
|
||||
if (!ignore_passability.blank()) {
|
||||
WRN_NG << "[teleport]ignore_passability= is deprecated, use check_passability=\n";
|
||||
if (!ignore_passability.to_bool(false))
|
||||
|
|
Loading…
Add table
Reference in a new issue