Skip to content

Commit d0f0b31

Browse files
committed
remove singleton
1 parent 075fa79 commit d0f0b31

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

library/src/main/java/com/gitonway/lee/niftymodaldialogeffects/lib/NiftyDialogBuilder.java

+1-9
Original file line numberDiff line numberDiff line change
@@ -106,15 +106,7 @@ protected void onCreate(Bundle savedInstanceState) {
106106

107107
public static NiftyDialogBuilder getInstance(Context context) {
108108

109-
if (instance == null || !tmpContext.equals(context)) {
110-
synchronized (NiftyDialogBuilder.class) {
111-
if (instance == null || !tmpContext.equals(context)) {
112-
instance = new NiftyDialogBuilder(context, R.style.dialog_untran);
113-
}
114-
}
115-
}
116-
tmpContext = context;
117-
return instance;
109+
return new NiftyDialogBuilder(context, R.style.dialog_untran);
118110

119111
}
120112

0 commit comments

Comments
 (0)