Fix limiting code