logic fix.