Bug caused by legacy code fixed.