fix issue 1022
Merge pull request #1038 from ahmetmircik/fixIsssue1022

fix issue 1022