Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2014-02-14 14:09:46 +01:00
commit a86440390c
2 changed files with 2 additions and 14 deletions

View File

@ -56,12 +56,9 @@ abstract class OptionsPropertyGroup extends OptionsPropertyItem
*/
public function removeProperty($property)
{
$this->_properties = array_udiff(
$this->_properties = array_diff(
$this->getProperties(),
array($property),
function ($a, $b) {
return ($a === $b ) ? 0 : 1;
}
array($property)
);
}

View File

@ -71,15 +71,6 @@ class PMA_OptionsPropertyGroup_Test extends PHPUnit_Framework_TestCase
$properties = new \ReflectionProperty('OptionsPropertyGroup', '_properties');
$properties->setAccessible(true);
$properties->setValue($this->stub, array(1, 2, 3, 'test'));
$this->stub->removeProperty('test');
$this->assertEquals(
array(1, 2, 3, 'test'),
$properties->getValue($this->stub)
);
$properties->setValue($this->stub, array(1, 2, 'test', 3));
$this->stub->removeProperty('test');