Fix syntax errors and missing code from earlier merge
Merge branch 'fixes-drs'