Removing duplicate option
Improving document root handling