fixing permalink -> id