Hyundai defines this poorly. Mostly the definition indicates that it's a
fuel trim (mixture) management issue. Most of the time I see one of these
codes, an oxygen sensor is stuck full rich or full lean.
If you have just one of these codes and the other oxygen sensor is
behaving normally, the issue is most likely the upstream oxygen sensor on
the bank in question (P1166 => rear bank, P1167 => front bank).
If you have both codes, you should first check things that could allow
extra/restrict air or fuel into both banks. Typically, this would include
fuel pressure issues, blocked air intake, leak in or improperly attached
air intake bellows, or other sizeable vacuum leaks.