Fixed safe mode bypass in Function constructor.

This closes #367 pull request on Github.

Thanks bux.patryk@gmail.com for prodding it.
2 files changed