The Black Codes -- which were aimed , as the Columbia University historian Eric Foner has noted , at keeping freed slaves ' status as close to slavery as possible -- went well beyond anything in the North .