Fixing empty row error