array options need to be dereferenced when checking

4 views
Skip to first unread message

Alfie

unread,
Nov 20, 2011, 10:13:51 PM11/20/11
to Percona Dev
Looking at pt-table-checksum (v2), options with type 'array' will
*always* be true (i.e. an array reference) in conditions such as:

if ( $o->get('progress') ) {
...
}

These need to be changed something like:

if ( @{ $o->get('progress') || [] } ) {
...
}

Reply all
Reply to author
Forward
0 new messages