Issue #339

Port PR #583 from Propel 1.6