Make changes for supporting both versions

Tested on 2.062 and 1.076
Merge pull request #2 from JesseKPhillips/d1support

Make changes for supporting both versions