patricktalmadge/bootstrapper — pull request #29 by Anahkiasen (2012-09-09 17:38:25+00:00)
Title: Fixed a bug in Buttons when calling multiple instances of Buttons without them printing immediatly

In yesterday's pull request a bug was introduced for this particular use case :

```php

```

Since none of the two buttons got to call __toString() before being outputed, the `$currentButton` got overwrote by the second button. This is fixed by making said variable part of the current instance instead of static. Tested with yesterday's homemade tests and the above situation, all is working.
This is the kind of situations where unit testing could have helped. Sorry again for the bug, hope nothing wrong pops up again.