Revert "simplify GetInstance return"
This reverts commit e167b65e142000a199d40724814143903f77b793.

The change breaks some php configurations.