private void DecreaseActivityCounter(Activity activity)
        {
            if (activeCounter > 0)
            {
                activeCounter--;

                if (activeCounter == 0)
                {
                    BranchAndroid.getInstance().CloseSession();
                }
            }
        }
        private void IncreaseActivityCounter(Activity activity)
        {
            if (activeCounter == 0)
            {
                if (callback != null)
                {
                    BranchAndroid.getInstance().InitSession(callback);
                }
                else if (callbackBUO != null)
                {
                    BranchAndroid.getInstance().InitSession(callbackBUO);
                }
            }

            activeCounter++;
        }
 public void OnActivityStarted(Activity activity)
 {
     BranchAndroid.getInstance().CurrActivity = activity;
     IncreaseActivityCounter(activity);
 }