fixed shared instance bug