Fixed bug in macro.