this is a little confusing. I understand that we are setting previous for the next call but still. maybe create a separate variable result and do previous = result.getBytes(); return result;