Issue #24 and Issue #26 fixes