Fix for bug