Issue #33: Code cleanup