Use explicit types with get_row
Auto types aren't very neat as return values because they move the burden of knowledge to the reader. Using an explicit, and somewhat self-explanatory, type makes it easier to assess the code without knowing the implementation of the type.
This commit is contained in:
@ -17,7 +17,7 @@ bool query(TestConnections& test)
|
||||
test.maxscales->connect();
|
||||
execute_query_silent(test.maxscales->conn_rwsplit[0], "SET @a = 1") == 0;
|
||||
sleep(5);
|
||||
auto row = get_row(test.maxscales->conn_rwsplit[0], "SELECT @a");
|
||||
Row row = get_row(test.maxscales->conn_rwsplit[0], "SELECT @a");
|
||||
test.maxscales->disconnect();
|
||||
return row[0] == "1";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user