nus-yam/ex-repair huggingface dataset:
Program: 114965
Project: 114965
Buggy source:
/** 
 * Generate user access key
 * @param consumeKey       - consumer  key of user
 * @param consumerSecret   - consumer secret key
 * @param messageBody      - message body
 * @param tokenEndpointURL - token endpoint url
 * @return - http response of generate access token api call
 * @throws APIManagerIntegrationTestException - throws if generating APIM access token fails
 */
public HttpResponse generateUserAccessKey(String consumeKey,String consumerSecret,String messageBody,URL tokenEndpointURL) throws APIManagerIntegrationTestException {
  try {
    checkAuthentication();
    Map<String,String> authenticationRequestHeaders=new HashMap<String,String>();
    String basicAuthHeader=consumeKey + "String_Node_Str" + consumerSecret;
    byte[] encodedBytes=Base64.encodeBase64(basicAuthHeader.getBytes());
    authenticationRequestHeaders.put("String_Node_Str","String_Node_Str");
    authenticationRequestHeaders.put("String_Node_Str","String_Node_Str" + new String(encodedBytes));
    return HttpRequestUtil.doPost(tokenEndpointURL,messageBody,authenticationRequestHeaders);
  }
 catch (  Exception e) {
    throw new APIManagerIntegrationTestException("String_Node_Str",e);
  }
}

Fixed version (ground truth):
/** 
 * Generate user access key
 * @param consumeKey       - consumer  key of user
 * @param consumerSecret   - consumer secret key
 * @param messageBody      - message body
 * @param tokenEndpointURL - token endpoint url
 * @return - http response of generate access token api call
 * @throws APIManagerIntegrationTestException - throws if generating APIM access token fails
 */
public HttpResponse generateUserAccessKey(String consumeKey,String consumerSecret,String messageBody,URL tokenEndpointURL) throws APIManagerIntegrationTestException {
  try {
    checkAuthentication();
    Map<String,String> authenticationRequestHeaders=new HashMap<String,String>();
    String basicAuthHeader=consumeKey + "String_Node_Str" + consumerSecret;
    byte[] encodedBytes=Base64.encodeBase64(basicAuthHeader.getBytes("String_Node_Str"));
    authenticationRequestHeaders.put("String_Node_Str","String_Node_Str");
    authenticationRequestHeaders.put("String_Node_Str","String_Node_Str" + new String(encodedBytes,"String_Node_Str"));
    return HttpRequestUtil.doPost(tokenEndpointURL,messageBody,authenticationRequestHeaders);
  }
 catch (  Exception e) {
    throw new APIManagerIntegrationTestException("String_Node_Str",e);
  }
}
Program: 114966
Project: 114966
Buggy source:
public static String getDecodedJWT(String serverMessage){
  String[] headerArray=serverMessage.split("String_Node_Str");
  String[] jwtEncodedArray=headerArray[1].trim().split("String_Node_Str");
  String[] jwtTokenArray=jwtEncodedArray[1].split(Pattern.quote("String_Node_Str"));
  byte[] jwtByteArray=Base64.decodeBase64(jwtTokenArray[1].getBytes());
  return new String(jwtByteArray);
}

Fixed version (ground truth):
public static String getDecodedJWT(String serverMessage) throws UnsupportedEncodingException {
  String[] headerArray=serverMessage.split("String_Node_Str");
  String[] jwtEncodedArray=headerArray[1].trim().split("String_Node_Str");
  String[] jwtTokenArray=jwtEncodedArray[1].split(Pattern.quote("String_Node_Str"));
  byte[] jwtByteArray=Base64.decodeBase64(jwtTokenArray[1].getBytes("String_Node_Str"));
  return new String(jwtByteArray,"String_Node_Str");
}
Program: 114967
Project: 114967
Buggy source:
public static void sendGetRequest(String url,String accessToken) throws XPathExpressionException, IOException {
  HttpResponse httpResponse;
  URL urlAPI=new URL(url);
  HttpURLConnection conn=(HttpURLConnection)urlAPI.openConnection();
  conn.setRequestMethod("String_Node_Str");
  conn.setDoOutput(true);
  conn.setReadTimeout(10000);
  conn.setRequestProperty("String_Node_Str","String_Node_Str" + accessToken);
  conn.connect();
  StringBuilder sb=new StringBuilder();
  BufferedReader rd=null;
  try {
    rd=new BufferedReader(new InputStreamReader(conn.getInputStream()));
    String line;
    while ((line=rd.readLine()) != null) {
      sb.append(line);
    }
    httpResponse=new HttpResponse(sb.toString(),conn.getResponseCode());
    httpResponse.setResponseMessage(conn.getResponseMessage());
  }
 catch (  IOException ignored) {
  }
 finally {
    if (rd != null) {
      rd.close();
    }
  }
}

Fixed version (ground truth):
public static void sendGetRequest(String url,String accessToken) throws XPathExpressionException, IOException {
  HttpResponse httpResponse;
  URL urlAPI=new URL(url);
  HttpURLConnection conn=(HttpURLConnection)urlAPI.openConnection();
  conn.setRequestMethod("String_Node_Str");
  conn.setDoOutput(true);
  conn.setReadTimeout(10000);
  conn.setRequestProperty("String_Node_Str","String_Node_Str" + accessToken);
  conn.connect();
  StringBuilder sb=new StringBuilder();
  BufferedReader rd=null;
  try {
    rd=new BufferedReader(new InputStreamReader(conn.getInputStream(),"String_Node_Str"));
    String line;
    while ((line=rd.readLine()) != null) {
      sb.append(line);
    }
    httpResponse=new HttpResponse(sb.toString(),conn.getResponseCode());
    httpResponse.setResponseMessage(conn.getResponseMessage());
  }
 catch (  IOException ignored) {
  }
 finally {
    if (rd != null) {
      rd.close();
    }
  }
}
Program: 114969
Project: 114969
Buggy source:
@Override public LayoutInflater getLayoutInflater(Bundle savedInstanceState){
  return mImpl.getLayoutInflater(savedInstanceState);
}

Fixed version (ground truth):
@Override public LayoutInflater getLayoutInflater(Bundle savedInstanceState){
  return mImpl.getLayoutInflater();
}
Program: 114970
Project: 114970
Buggy source:
@Override public LayoutInflater getLayoutInflater(Bundle savedInstanceState){
  return mImpl.getLayoutInflater(savedInstanceState);
}

Fixed version (ground truth):
@Override public LayoutInflater getLayoutInflater(Bundle savedInstanceState){
  return mImpl.getLayoutInflater();
}
Program: 114971
Project: 114971
Buggy source:
void restoreAllState(Parcelable state){
  if (state != null) {
    FragmentMasterState fms=(FragmentMasterState)state;
    mFragments.clear();
    Bundle fragments=fms.mFragments;
    if (fragments != null) {
      Iterable<String> keys=fragments.keySet();
      for (      String key : keys) {
        if (key.startsWith("String_Node_Str")) {
          int index=Integer.parseInt(key.substring(1));
          MasterFragment f=(MasterFragment)mFragmentManager.getFragment(fragments,key);
          if (f != null) {
            while (mFragments.size() <= index) {
              mFragments.add(null);
            }
            f.setMenuVisibility(false);
            mFragments.set(index,f);
          }
 else {
            Log.w(TAG,"String_Node_Str" + key);
          }
        }
      }
    }
    setSlideEnable(fms.mIsSlideEnable);
  }
}

Fixed version (ground truth):
void restoreAllState(Parcelable state){
  if (state != null) {
    FragmentMasterState fms=(FragmentMasterState)state;
    mFragments.clear();
    Bundle fragments=fms.mFragments;
    if (fragments != null) {
      Iterable<String> keys=fragments.keySet();
      for (      String key : keys) {
        if (key.startsWith("String_Node_Str")) {
          int index=Integer.parseInt(key.substring(1));
          MasterFragment f=(MasterFragment)mFragmentManager.getFragment(fragments,key);
          if (f != null) {
            while (mFragments.size() <= index) {
              mFragments.add(null);
            }
            f.setMenuVisibility(false);
            mFragments.set(index,f);
          }
 else {
            Log.w(TAG,"String_Node_Str" + key);
          }
        }
      }
    }
    setSlideEnable(fms.mIsSlideEnable);
    mHomeFragmentApplied=fms.mHomeFragmemtApplied;
  }
}
Program: 114972
Project: 114972
Buggy source:
Parcelable saveAllState(){
  FragmentMasterState state=new FragmentMasterState();
  Bundle fragments=null;
  for (int i=0; i < mFragments.size(); i++) {
    Fragment f=mFragments.get(i);
    if (f != null) {
      if (fragments == null) {
        fragments=new Bundle();
      }
      String key="String_Node_Str" + i;
      mFragmentManager.putFragment(fragments,key,f);
    }
  }
  state.mFragments=fragments;
  state.mIsSlideEnable=mIsSlideEnable;
  return state;
}

Fixed version (ground truth):
Parcelable saveAllState(){
  FragmentMasterState state=new FragmentMasterState();
  Bundle fragments=null;
  for (int i=0; i < mFragments.size(); i++) {
    Fragment f=mFragments.get(i);
    if (f != null) {
      if (fragments == null) {
        fragments=new Bundle();
      }
      String key="String_Node_Str" + i;
      mFragmentManager.putFragment(fragments,key,f);
    }
  }
  state.mFragments=fragments;
  state.mIsSlideEnable=mIsSlideEnable;
  state.mHomeFragmemtApplied=mHomeFragmentApplied;
  return state;
}
Program: 114973
Project: 114973
Buggy source:
public FragmentMasterState(Parcel in){
  mFragments=in.readBundle();
  mIsSlideEnable=in.readInt() == 0;
}

Fixed version (ground truth):
public FragmentMasterState(Parcel in){
  mFragments=in.readBundle();
  mIsSlideEnable=in.readInt() == 0;
  mHomeFragmemtApplied=in.readInt() == 0;
}
Program: 114974
Project: 114974
Buggy source:
public final void install(int containerResID,Request homeRequest,boolean sticky){
  if (isInstalled()) {
    throw new IllegalStateException("String_Node_Str");
  }
 else {
    mContainerResID=containerResID;
    checkInstallProperties();
    performInstall(mContainer);
    mIsInstalled=true;
    if (homeRequest != null) {
      mSticky=sticky;
      if (getFragments().size() == 0) {
        startFragmentForResult(null,homeRequest,-1);
      }
    }
  }
}

Fixed version (ground truth):
public final void install(int containerResID,Request homeRequest,boolean sticky){
  if (isInstalled()) {
    throw new IllegalStateException("String_Node_Str");
  }
 else {
    mContainerResID=containerResID;
    checkInstallProperties();
    performInstall(mContainer);
    mIsInstalled=true;
    if (homeRequest != null) {
      applyHomeFragment(homeRequest,sticky);
    }
  }
}
Program: 114975
Project: 114975
Buggy source:
@Override public void writeToParcel(Parcel dest,int flags){
  dest.writeBundle(mFragments);
  dest.writeInt(mIsSlideEnable ? 0 : 1);
}

Fixed version (ground truth):
@Override public void writeToParcel(Parcel dest,int flags){
  dest.writeBundle(mFragments);
  dest.writeInt(mIsSlideEnable ? 0 : 1);
  dest.writeInt(mHomeFragmemtApplied ? 0 : 1);
}
Program: 114976
Project: 114976
Buggy source:
final boolean dispatchKeyEventToActivity(KeyEvent event){
  final View decor=mActivity.getWindow().getDecorView();
  return KeyEventCompat.dispatch(event,mActivity,decor != null ? KeyEventCompat.getKeyDispatcherState(decor) : null,mActivity);
}

Fixed version (ground truth):
final boolean dispatchKeyEventToActivity(KeyEvent event){
  final View decor=mActivity.getWindow().getDecorView();
  return KeyEventCompat2.dispatch(event,mActivity,decor != null ? KeyEventCompat2.getKeyDispatcherState(decor) : null,mActivity);
}
Program: 114977
Project: 114977
Buggy source:
public boolean dispatchKeyEvent(KeyEvent event){
  if (getFragmentMaster().dispatchKeyEventToWindow(event)) {
    return true;
  }
  View view=mMasterFragment.getView();
  boolean handled=KeyEventCompat.dispatch(event,mMasterFragment,view != null ? KeyEventCompat.getKeyDispatcherState(view) : null,this);
  if (handled) {
    return true;
  }
  return getFragmentMaster().dispatchKeyEventToActivity(event);
}

Fixed version (ground truth):
public boolean dispatchKeyEvent(KeyEvent event){
  if (getFragmentMaster().dispatchKeyEventToWindow(event)) {
    return true;
  }
  View view=mMasterFragment.getView();
  boolean handled=KeyEventCompat2.dispatch(event,mMasterFragment,view != null ? KeyEventCompat2.getKeyDispatcherState(view) : null,this);
  if (handled) {
    return true;
  }
  return getFragmentMaster().dispatchKeyEventToActivity(event);
}
Program: 114978
Project: 114978
Buggy source:
private void performUserLeave(){
  mIsUserActive=false;
  onUserLeave();
}

Fixed version (ground truth):
private void performUserLeave(){
  mIsUserActive=false;
  mMasterFragment.onUserLeave();
}
Program: 114979
Project: 114979
Buggy source:
private void performUserActive(){
  mIsUserActive=true;
  onUserActive();
}

Fixed version (ground truth):
private void performUserActive(){
  mIsUserActive=true;
  mMasterFragment.onUserActive();
}
Program: 114980
Project: 114980
Buggy source:
@Override public void destroyItem(ViewGroup container,int position,Object object){
  IMasterFragment f=(IMasterFragment)object;
  if (getFragments().contains(f)) {
    f.finish();
  }
}

Fixed version (ground truth):
@Override public void destroyItem(ViewGroup container,int position,Object object){
}
Program: 114981
Project: 114981
Buggy source:
public MasterFragmentState(Parcel in){
  mRequest=in.readParcelable(null);
  mSoftInputMode=in.readInt();
  mIsSlideable=in.readInt() != 0;
}

Fixed version (ground truth):
public MasterFragmentState(Parcel in){
  mRequest=in.readParcelable(MasterFragmentState.class.getClassLoader());
  mSoftInputMode=in.readInt();
  mIsSlideable=in.readInt() != 0;
}
Program: 114983
Project: 114983
Buggy source:
public EventService(SessionManager sessionManager){
  this.dataSource=sessionManager.getDataSource();
}

Fixed version (ground truth):
public EventService(DataSource dataSource){
  super();
  this.dataSource=dataSource;
}
Program: 114986
Project: 114986
Buggy source:
private UserAccount getCurrentUser(){
  UserAccount ub=getUserAccountDao().findById(1);
  return ub;
}

Fixed version (ground truth):
private UserAccount getCurrentUser(){
  UserAccount ub=getUserDaoDomain().findById(1);
  return ub;
}
Program: 114987
Project: 114987
Buggy source:
public void setEventService(EventService eventService){
  this.eventService=eventService;
}

Fixed version (ground truth):
public void setEventService(EventServiceInterface eventService){
  this.eventService=eventService;
}
Program: 114989
Project: 114989
Buggy source:
public OdmImportServiceImpl(DataSource dataSource){
  this.dataSource=dataSource;
}

Fixed version (ground truth):
public OdmImportServiceImpl(UserAccountDao userDaoDomain,StudyUserRoleDao studyUserRoleDao,StudyEventDefinitionDao studyEventDefDao,EventDefinitionCrfDao eventDefinitionCrfDao,CrfDao crfDao,CrfVersionDao crfVersionDao,FormLayoutDao formLayoutDao,StudyDao studyDao,EventDefinitionCrfTagDao eventDefinitionCrfTagDao,StudyParameterValueDao studyParameterValueDao,DataSource dataSource,XformParser xformParser,XformMetaDataService xformService,CoreResources coreResources,EventServiceInterface eventService,PageLayoutDao pageLayoutDao){
  super();
  this.userDaoDomain=userDaoDomain;
  this.studyUserRoleDao=studyUserRoleDao;
  this.studyEventDefDao=studyEventDefDao;
  this.eventDefinitionCrfDao=eventDefinitionCrfDao;
  this.crfDao=crfDao;
  this.crfVersionDao=crfVersionDao;
  this.formLayoutDao=formLayoutDao;
  this.studyDao=studyDao;
  this.eventDefinitionCrfTagDao=eventDefinitionCrfTagDao;
  this.studyParameterValueDao=studyParameterValueDao;
  this.dataSource=dataSource;
  this.xformParser=xformParser;
  this.xformService=xformService;
  this.coreResources=coreResources;
  this.eventService=eventService;
  this.pageLayoutDao=pageLayoutDao;
}
Program: 114990
Project: 114990
Buggy source:
public UserAccountDao getUserAccountDao(){
  return userAccountDao;
}

Fixed version (ground truth):
public UserAccountDao getUserAccountDao(){
  return userDaoDomain;
}
Program: 114991
Project: 114991
Buggy source:
public void setUserAccountDao(UserAccountDao userAccountDao){
  this.userAccountDao=userAccountDao;
}

Fixed version (ground truth):
public void setUserAccountDao(UserAccountDao userAccountDao){
  this.userDaoDomain=userAccountDao;
}
Program: 114996
Project: 114996
Buggy source:
public static UserAccountBean setRootUserAccountBean(HttpServletRequest request,DataSource dataSource){
  UserAccountDAO userAccountDAO=new UserAccountDAO(dataSource);
  UserAccountBean ub=(UserAccountBean)userAccountDAO.findByUserName("String_Node_Str");
  ArrayList userRoleBeans=(ArrayList)userAccountDAO.findAllRolesByUserName(ub.getName());
  ub.setRoles(userRoleBeans);
  if (ub.getId() != 0) {
    request.getSession().setAttribute("String_Node_Str",ub);
  }
  return ub;
}

Fixed version (ground truth):
public static UserAccountBean setRootUserAccountBean(HttpServletRequest request,DataSource dataSource){
  UserAccountDAO userAccountDAO=new UserAccountDAO(dataSource);
  UserAccountBean ub=(UserAccountBean)userAccountDAO.findByUserName("String_Node_Str");
  if (ub.getId() != 0) {
    request.getSession().setAttribute("String_Node_Str",ub);
  }
  return ub;
}
Program: 114998
Project: 114998
Buggy source:
public ArrayList getEventDefinitionsByCurrentStudy(){
  StudyDAO studyDAO=new StudyDAO(sm.getDataSource());
  StudyEventDefinitionDAO studyEventDefinitionDAO=new StudyEventDefinitionDAO(sm.getDataSource());
  int parentStudyId=currentStudy.getParentStudyId();
  ArrayList allDefs=new ArrayList();
  if (parentStudyId > 0) {
    StudyBean parentStudy=(StudyBean)studyDAO.findByPK(parentStudyId);
    allDefs=studyEventDefinitionDAO.findAllActiveByStudy(parentStudy);
  }
 else {
    parentStudyId=currentStudy.getId();
    allDefs=studyEventDefinitionDAO.findAllActiveByStudy(currentStudy);
  }
  return allDefs;
}

Fixed version (ground truth):
public ArrayList getEventDefinitionsByCurrentStudy(){
  StudyDAO studyDAO=new StudyDAO(sm.getDataSource());
  StudyEventDefinitionDAO studyEventDefinitionDAO=new StudyEventDefinitionDAO(sm.getDataSource());
  ArrayList allDefs=new ArrayList();
  if (currentStudy == null)   return allDefs;
  int parentStudyId=currentStudy.getParentStudyId();
  if (parentStudyId > 0) {
    StudyBean parentStudy=(StudyBean)studyDAO.findByPK(parentStudyId);
    allDefs=studyEventDefinitionDAO.findAllActiveByStudy(parentStudy);
  }
 else {
    parentStudyId=currentStudy.getId();
    allDefs=studyEventDefinitionDAO.findAllActiveByStudy(currentStudy);
  }
  return allDefs;
}
Program: 115000
Project: 115000
Buggy source:
public static Status getByName(String name){
  for (int i=0; i < list.size(); i++) {
    Status temp=(Status)list.get(i);
    if (temp.getName().equalsIgnoreCase(name)) {
      return temp;
    }
  }
  return INVALID;
}

Fixed version (ground truth):
public static Status getByName(String name){
  for (int i=0; i < list.size(); i++) {
    Status temp=(Status)list.get(i);
    name=name.equalsIgnoreCase("String_Node_Str") ? "String_Node_Str" : name;
    if (temp.getName().equalsIgnoreCase(name)) {
      return temp;
    }
  }
  return INVALID;
}
Program: 115001
Project: 115001
Buggy source:
private UserAccountBean createUserAccount(HttpServletRequest request,Auth0User user,Map<String,Object> userContextMap) throws Exception {
  HashMap<String,String> map=new HashMap<>();
  map.put("String_Node_Str",user.getNickname());
  if (StringUtils.isNotEmpty(user.getGivenName()))   map.put("String_Node_Str",user.getGivenName());
 else   map.put("String_Node_Str","String_Node_Str");
  if (StringUtils.isNotEmpty(user.getFamilyName()))   map.put("String_Node_Str",user.getFamilyName());
 else   map.put("String_Node_Str","String_Node_Str");
  map.put("String_Node_Str","String_Node_Str");
  map.put("String_Node_Str",(String)userContextMap.get("String_Node_Str"));
  String userType=(String)userContextMap.get("String_Node_Str");
  String convertedUserType=null;
switch (userType) {
case "String_Node_Str":
    convertedUserType=UserType.SYSADMIN.getName();
  break;
case "String_Node_Str":
convertedUserType=UserType.TECHADMIN.getName();
break;
case "String_Node_Str":
convertedUserType=UserType.USER.getName();
break;
default :
String error="String_Node_Str" + userType;
logger.error(error);
throw new Exception(error);
}
map.put("String_Node_Str",convertedUserType);
map.put("String_Node_Str","String_Node_Str");
map.put("String_Node_Str",user.getEmail());
map.put("String_Node_Str","String_Node_Str");
CoreResources.setRootUserAccountBean(request,dataSource);
userAccountController.createOrUpdateAccount(request,map);
return (UserAccountBean)request.getAttribute("String_Node_Str");
}

Fixed version (ground truth):
private UserAccountBean createUserAccount(HttpServletRequest request,Auth0User user,Map<String,Object> userContextMap) throws Exception {
  HashMap<String,String> map=new HashMap<>();
  map.put("String_Node_Str",user.getNickname());
  if (StringUtils.isNotEmpty(user.getGivenName()))   map.put("String_Node_Str",user.getGivenName());
 else   map.put("String_Node_Str","String_Node_Str");
  if (StringUtils.isNotEmpty(user.getFamilyName()))   map.put("String_Node_Str",user.getFamilyName());
 else   map.put("String_Node_Str","String_Node_Str");
  map.put("String_Node_Str","String_Node_Str");
  map.put("String_Node_Str",(String)userContextMap.get("String_Node_Str"));
  String userType=(String)userContextMap.get("String_Node_Str");
  map.put("String_Node_Str",userType);
  map.put("String_Node_Str","String_Node_Str");
  map.put("String_Node_Str",user.getEmail());
  map.put("String_Node_Str","String_Node_Str");
  CoreResources.setRootUserAccountBean(request,dataSource);
  userAccountController.createOrUpdateAccount(request,map);
  return (UserAccountBean)request.getAttribute("String_Node_Str");
}
Program: 115003
Project: 115003
Buggy source:
private Status getStatus(String myStatus){
  Status statusObj=null;
  if (myStatus != null) {
    myStatus=myStatus.equals("String_Node_Str") ? "String_Node_Str" : myStatus;
    statusObj=Status.getByName(myStatus.toLowerCase());
  }
  return statusObj;
}

Fixed version (ground truth):
private Status getStatus(String myStatus){
  Status statusObj=null;
  if (myStatus != null) {
    statusObj=Status.getByName(myStatus.toLowerCase());
  }
  return statusObj;
}
Program: 115004
Project: 115004
Buggy source:
public void createStudySchema(String schemaName) throws Exception {
  Query schemaQuery=getCurrentSession().createNativeQuery("String_Node_Str" + schemaName + "String_Node_Str");
  schemaQuery.executeUpdate();
}

Fixed version (ground truth):
public void createStudySchema(String schemaName) throws Exception {
  String dbUser=CoreResources.getField("String_Node_Str");
  Query schemaQuery=getCurrentSession().createNativeQuery("String_Node_Str" + schemaName + "String_Node_Str"+ dbUser);
  schemaQuery.executeUpdate();
}
Program: 115005
Project: 115005
Buggy source:
public boolean saveStudyEnvRoles(HttpServletRequest request,UserAccountBean ubIn) throws Exception {
  UserAccount ub=userAccountDao.findByUserId(ubIn.getId());
  boolean studyUserRoleUpdated=false;
  int userActiveStudyId;
  if (ub.getActiveStudy() == null)   userActiveStudyId=0;
 else   userActiveStudyId=ub.getActiveStudy().getStudyId();
  boolean studyEnvUuidProcessed=processSpecificStudyEnvUuid(request,userActiveStudyId,ub);
  if (studyEnvUuidProcessed)   return true;
  CoreResources.setRequestSchema(request,"String_Node_Str");
  studyUserRoleUpdated=updateStudyUserRoles(request,ub,userActiveStudyId);
  if (ub.getActiveStudy() == null) {
    logger.error("String_Node_Str");
    return false;
  }
 else   if (ub.getActiveStudy().getStudyId() == 0) {
    throw new Exception("String_Node_Str");
  }
  if (studyUserRoleUpdated) {
    return true;
  }
 else   return false;
}

Fixed version (ground truth):
public boolean saveStudyEnvRoles(HttpServletRequest request,UserAccountBean ubIn) throws Exception {
  UserAccount ub=userAccountDao.findByUserId(ubIn.getId());
  boolean studyUserRoleUpdated=false;
  int userActiveStudyId;
  if (ub.getActiveStudy() == null)   userActiveStudyId=0;
 else   userActiveStudyId=ub.getActiveStudy().getStudyId();
  boolean studyEnvUuidProcessed=processSpecificStudyEnvUuid(request,userActiveStudyId,ub);
  if (studyEnvUuidProcessed)   return true;
  studyUserRoleUpdated=updateStudyUserRoles(request,ub,userActiveStudyId);
  if (ub.getActiveStudy() == null) {
    logger.error("String_Node_Str");
    return false;
  }
 else   if (ub.getActiveStudy().getStudyId() == 0) {
    throw new Exception("String_Node_Str");
  }
  if (studyUserRoleUpdated) {
    return true;
  }
 else   return false;
}
Program: 115012
Project: 115012
Buggy source:
private StudyParameterConfig processStudyConfigParameters(HashMap<String,Object> map,ArrayList<ErrorObject> errorObjects){
  StudyParameterConfig spc=new StudyParameterConfig();
  String collectBirthDate=(String)map.get("String_Node_Str");
  Boolean collectSex=(Boolean)map.get("String_Node_Str");
  String collectPersonId=(String)map.get("String_Node_Str");
  Boolean showSecondaryId=(Boolean)map.get("String_Node_Str");
  if (collectBirthDate == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
 else {
    collectBirthDate=collectBirthDate.trim();
  }
  spc.setCollectDob(collectBirthDate);
  if (collectSex == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
  spc.setGenderRequired(Boolean.toString(collectSex));
  if (collectPersonId == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
 else {
    collectPersonId=collectPersonId.trim();
  }
  spc.setSubjectPersonIdRequired(collectPersonId);
  if (showSecondaryId == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
  spc.setSecondaryLabelViewable(Boolean.toString(showSecondaryId));
  return spc;
}

Fixed version (ground truth):
private StudyParameterConfig processStudyConfigParameters(HashMap<String,Object> map,ArrayList<ErrorObject> errorObjects){
  StudyParameterConfig spc=new StudyParameterConfig();
  String collectBirthDate=(String)map.get("String_Node_Str");
  Boolean collectSex=(Boolean)map.get("String_Node_Str");
  String collectPersonId=(String)map.get("String_Node_Str");
  if (collectBirthDate == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
 else {
    collectBirthDate=collectBirthDate.trim();
  }
  spc.setCollectDob(collectBirthDate);
  if (collectSex == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
  spc.setGenderRequired(Boolean.toString(collectSex));
  if (collectPersonId == null) {
    ErrorObject errorObject=createErrorObject("String_Node_Str","String_Node_Str","String_Node_Str");
    errorObjects.add(errorObject);
  }
 else {
    collectPersonId=collectPersonId.trim();
  }
  spc.setSubjectPersonIdRequired(collectPersonId);
  return spc;
}
Program: 115014
Project: 115014
Buggy source:
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccountBean ub){
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  String currentSchema=CoreResources.getRequestSchema();
  CoreResources.setRequestSchema("String_Node_Str");
  StudyDAO sd=getStudyDAO();
  StudyBean study=sd.findByStudyEnvUuid(studyEnvUuid);
  if (study == null) {
    CoreResources.setRequestSchema(currentSchema);
    return;
  }
  currentPublicStudy=study;
  CoreResources.setRequestSchema(currentPublicStudy.getSchemaName());
  currentStudy=sd.findByStudyEnvUuid(studyEnvUuid);
  session.setAttribute("String_Node_Str",currentPublicStudy);
  session.setAttribute("String_Node_Str",currentStudy);
  int parentStudyId=study.getParentStudyId() > 0 ? study.getParentStudyId() : study.getId();
  if (ub.getActiveStudyId() == parentStudyId)   return;
  ub.setActiveStudyId(parentStudyId);
}

Fixed version (ground truth):
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccountBean ub){
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  String currentSchema=CoreResources.getRequestSchema();
  CoreResources.setRequestSchema("String_Node_Str");
  StudyDAO sd=getStudyDAO();
  StudyBean study=sd.findByStudyEnvUuid(studyEnvUuid);
  if (study == null) {
    CoreResources.setRequestSchema(currentSchema);
    return;
  }
  currentPublicStudy=study;
  CoreResources.setRequestSchema(currentPublicStudy.getSchemaName());
  currentStudy=sd.findByStudyEnvUuid(studyEnvUuid);
  session.setAttribute("String_Node_Str",currentPublicStudy);
  session.setAttribute("String_Node_Str",currentStudy);
  int parentStudyId=currentPublicStudy.getParentStudyId() > 0 ? currentPublicStudy.getParentStudyId() : currentPublicStudy.getId();
  StudyUserRoleBean roleInParent=ub.getRoleByStudy(parentStudyId);
  currentRole.setRole(Role.max(currentRole.getRole(),roleInParent.getRole()));
  session.setAttribute("String_Node_Str",currentRole);
  if (ub.getActiveStudyId() == parentStudyId)   return;
  ub.setActiveStudyId(parentStudyId);
}
Program: 115016
Project: 115016
Buggy source:
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) protected String home(final Map<String,Object> model,final HttpServletRequest req){
  HttpSession session=req.getSession();
  logger.info("String_Node_Str");
  SessionUtils.setState(req,"String_Node_Str");
  NonceUtils.addNonceToStorage(req);
  setupModel(model,req);
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  SecurityContextHolder.clearContext();
  session.invalidate();
  return "String_Node_Str";
}

Fixed version (ground truth):
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) protected String home(final Map<String,Object> model,final HttpServletRequest req){
  HttpSession session=req.getSession();
  logger.info("String_Node_Str");
  SessionUtils.setState(req,"String_Node_Str");
  NonceUtils.addNonceToStorage(req);
  setupModel(model,req);
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  session.removeAttribute("String_Node_Str");
  SecurityContextHolder.clearContext();
  session.invalidate();
  model.put("String_Node_Str",req.getParameter("String_Node_Str"));
  return "String_Node_Str";
}
Program: 115017
Project: 115017
Buggy source:
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccount ub){
  HttpSession session=request.getSession();
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  StudyDAO studyDAO=new StudyDAO(dataSource);
  StudyBean currentPublicStudy=studyDAO.findByStudyEnvUuid(studyEnvUuid);
  Study userStudy=studyDao.findByStudyEnvUuid(studyEnvUuid);
  if (currentPublicStudy == null) {
    return;
  }
  int parentStudyId=currentPublicStudy.getParentStudyId() > 0 ? currentPublicStudy.getParentStudyId() : currentPublicStudy.getId();
  if (ub.getActiveStudy() != null && ub.getActiveStudy().getStudyId() == parentStudyId)   return;
  ub.setActiveStudy(userStudy);
  userAccountDao.saveOrUpdate(ub);
  session.setAttribute("String_Node_Str",null);
  session.setAttribute("String_Node_Str",null);
}

Fixed version (ground truth):
public boolean processSpecificStudyEnvUuid(HttpServletRequest request,int userActiveStudyId,UserAccount ub){
  boolean allUserRolesUpdated=false;
  HttpSession session=request.getSession();
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return allUserRolesUpdated;
  StudyDAO studyDAO=new StudyDAO(dataSource);
  StudyBean currentPublicStudy=studyDAO.findByStudyEnvUuid(studyEnvUuid);
  Study userStudy=studyDao.findByStudyEnvUuid(studyEnvUuid);
  if (currentPublicStudy == null) {
    return allUserRolesUpdated;
  }
  int parentStudyId=currentPublicStudy.getParentStudyId() > 0 ? currentPublicStudy.getParentStudyId() : currentPublicStudy.getId();
  if (ub.getActiveStudy() != null && ub.getActiveStudy().getStudyId() == parentStudyId)   return allUserRolesUpdated;
  ArrayList<StudyUserRole> userRoles=studyUserRoleDao.findAllUserRolesByUserAccount(ub,currentPublicStudy.getId(),parentStudyId);
  if (userRoles.isEmpty()) {
    updateStudyUserRoles(request,ub,userActiveStudyId);
    allUserRolesUpdated=true;
    userRoles=studyUserRoleDao.findAllUserRolesByUserAccount(ub,currentPublicStudy.getId(),parentStudyId);
    if (userRoles.isEmpty()) {
      logger.error("String_Node_Str" + currentPublicStudy.getStudyEnvUuid());
      return allUserRolesUpdated;
    }
  }
  StudyUserRoleBean studyUserRoleBean=new StudyUserRoleBean();
  ub.setActiveStudy(userStudy);
  userAccountDao.saveOrUpdate(ub);
  session.setAttribute("String_Node_Str",null);
  session.setAttribute("String_Node_Str",null);
  return allUserRolesUpdated;
}
Program: 115019
Project: 115019
Buggy source:
public static boolean setRequestSchema(String schema){
  ServletRequestAttributes requestAttributes=(ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
  if (requestAttributes != null && requestAttributes.getRequest() != null) {
    HttpServletRequest request=requestAttributes.getRequest();
    request.setAttribute("String_Node_Str",schema);
    return true;
  }
  return false;
}

Fixed version (ground truth):
public static void setRequestSchema(HttpServletRequest request,String schema){
  request.setAttribute("String_Node_Str",schema);
}
Program: 115020
Project: 115020
Buggy source:
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccountBean ub){
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  StudyDAO sd=getStudyDAO();
  StudyBean study=sd.findByStudyEnvUuid(studyEnvUuid);
  if (study == null)   return;
  int parentStudyId=study.getParentStudyId() > 0 ? study.getParentStudyId() : study.getId();
  if (ub.getActiveStudyId() == parentStudyId)   return;
  ub.setActiveStudyId(parentStudyId);
}

Fixed version (ground truth):
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccountBean ub){
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  String currentSchema=CoreResources.getRequestSchema();
  CoreResources.setRequestSchema("String_Node_Str");
  StudyDAO sd=getStudyDAO();
  StudyBean study=sd.findByStudyEnvUuid(studyEnvUuid);
  if (study == null) {
    CoreResources.setRequestSchema(currentSchema);
    return;
  }
  currentPublicStudy=study;
  CoreResources.setRequestSchema(currentPublicStudy.getSchemaName());
  currentStudy=sd.findByStudyEnvUuid(studyEnvUuid);
  session.setAttribute("String_Node_Str",currentPublicStudy);
  session.setAttribute("String_Node_Str",currentStudy);
  int parentStudyId=study.getParentStudyId() > 0 ? study.getParentStudyId() : study.getId();
  if (ub.getActiveStudyId() == parentStudyId)   return;
  ub.setActiveStudyId(parentStudyId);
}
Program: 115021
Project: 115021
Buggy source:
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccount ub){
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  Study study=studyDao.findByStudyEnvUuid(studyEnvUuid);
  if (study == null)   return;
  Study parentStudy=study.getStudy();
  Study toUpdate=parentStudy == null ? study : study.getStudy();
  ub.setActiveStudy(toUpdate);
  userAccountDao.saveOrUpdate(ub);
}

Fixed version (ground truth):
public void processSpecificStudyEnvUuid(HttpServletRequest request,UserAccount ub){
  HttpSession session=request.getSession();
  String studyEnvUuid=(String)request.getParameter("String_Node_Str");
  if (StringUtils.isEmpty(studyEnvUuid))   return;
  StudyDAO studyDAO=new StudyDAO(dataSource);
  StudyBean currentPublicStudy=studyDAO.findByStudyEnvUuid(studyEnvUuid);
  Study userStudy=studyDao.findByStudyEnvUuid(studyEnvUuid);
  if (currentPublicStudy == null) {
    return;
  }
  int parentStudyId=currentPublicStudy.getParentStudyId() > 0 ? currentPublicStudy.getParentStudyId() : currentPublicStudy.getId();
  if (ub.getActiveStudy() != null && ub.getActiveStudy().getStudyId() == parentStudyId)   return;
  ub.setActiveStudy(userStudy);
  userAccountDao.saveOrUpdate(ub);
  session.setAttribute("String_Node_Str",null);
  session.setAttribute("String_Node_Str",null);
}
Program: 115023
Project: 115023
Buggy source:
public UserAccount findByUserName(String userName){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + getDomainClassName() + "String_Node_Str";
  org.hibernate.Query q=getCurrentSession().createQuery(query);
  q.setString("String_Node_Str",userName);
  return (UserAccount)q.uniqueResult();
}

Fixed version (ground truth):
public UserAccount findByUserName(String userName){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + getDomainClassName() + "String_Node_Str";
  Query q=getCurrentSession().createQuery(query);
  q.setParameter("String_Node_Str",userName);
  return (UserAccount)q.uniqueResult();
}
Program: 115024
Project: 115024
Buggy source:
public UserAccount findByUserId(Integer userId){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + getDomainClassName() + "String_Node_Str";
  org.hibernate.Query q=getCurrentSession().createQuery(query);
  q.setInteger("String_Node_Str",userId);
  return (UserAccount)q.uniqueResult();
}

Fixed version (ground truth):
public UserAccount findByUserId(Integer userId){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + getDomainClassName() + "String_Node_Str";
  Query q=getCurrentSession().createQuery(query);
  q.setParameter("String_Node_Str",userId);
  return (UserAccount)q.uniqueResult();
}
Program: 115025
Project: 115025
Buggy source:
public List<UserAccount> findNonRootNonParticipateUsersByStudyId(Integer studyId,Integer parentStudyId){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + "String_Node_Str" + studyId + "String_Node_Str"+ parentStudyId+ "String_Node_Str";
  org.hibernate.Query q=getCurrentSession().createSQLQuery(query).addEntity(UserAccount.class);
  return (List<UserAccount>)q.list();
}

Fixed version (ground truth):
public List<UserAccount> findNonRootNonParticipateUsersByStudyId(Integer studyId,Integer parentStudyId){
  getSessionFactory().getStatistics().logSummary();
  String query="String_Node_Str" + "String_Node_Str" + studyId + "String_Node_Str"+ parentStudyId+ "String_Node_Str";
  Query q=getCurrentSession().createNativeQuery(query).addEntity(UserAccount.class);
  return (List<UserAccount>)q.list();
}
Program: 115026
Project: 115026
Buggy source:
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) protected void callback(final HttpServletRequest req,final HttpServletResponse res) throws Exception {
  SessionUtils.setState(req,"String_Node_Str");
  NonceUtils.addNonceToStorage(req);
  super.handle(req,res);
  Tokens tokens=SessionUtils.getTokens(req);
  Auth0User user=SessionUtils.getAuth0User(req);
  req.getSession().setAttribute("String_Node_Str",tokens.getAccessToken());
  UserAccountBean ub=callbackService.isCallbackSuccessful(req,user);
  if (ub != null) {
    req.getSession().setAttribute(USER_BEAN_NAME,ub);
  }
 else {
    unauthorized(res,"String_Node_Str");
    return;
  }
}

Fixed version (ground truth):
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) protected void callback(final HttpServletRequest req,final HttpServletResponse res) throws Exception {
  SessionUtils.setState(req,"String_Node_Str");
  NonceUtils.addNonceToStorage(req);
  super.handle(req,res);
  Tokens tokens=SessionUtils.getTokens(req);
  Auth0User user=SessionUtils.getAuth0User(req);
  req.getSession().setAttribute("String_Node_Str",tokens.getAccessToken());
  UserAccountHelper userAccountHelper=callbackService.isCallbackSuccessful(req,user);
  UserAccountBean ub=userAccountHelper.getUb();
  if (ub != null) {
    if (userAccountHelper.isUpdated())     ub=callbackService.getUpdatedUser(ub);
    req.getSession().setAttribute(USER_BEAN_NAME,ub);
  }
 else {
    unauthorized(res,"String_Node_Str");
    return;
  }
}
Program: 115028
Project: 115028
Buggy source:
private ResponseEntity<Object> processStudyAsync(HttpServletRequest request,String validation_passed_message,Study study,UserAccountBean ownerUserAccount) throws Exception {
  ResponseEntity<Object> response;
  Locale locale=new Locale("String_Node_Str");
  request.getSession().setAttribute(LocaleResolver.getLocaleSessionAttributeName(),locale);
  ResourceBundleProvider.updateLocale(locale);
  StudyInfoObject studyInfoObject=studyBuildService.process(request,study,ownerUserAccount);
  AsyncStudyHelper asyncStudyHelper=new AsyncStudyHelper("String_Node_Str","String_Node_Str");
  AsyncStudyHelper.put(study.getUniqueIdentifier(),asyncStudyHelper);
  liquibaseOnDemandService.createForeignTables(studyInfoObject);
  Study schemaStudy=liquibaseOnDemandService.process(studyInfoObject,ownerUserAccount);
  logger.debug("String_Node_Str" + schemaStudy.getStudyId());
  logger.debug("String_Node_Str" + schemaStudy.getOc_oid());
  ResponseSuccessStudyDTO responseSuccess=new ResponseSuccessStudyDTO();
  responseSuccess.setMessage(validation_passed_message);
  responseSuccess.setStudyOid(schemaStudy.getOc_oid());
  responseSuccess.setUniqueStudyID(schemaStudy.getUniqueIdentifier());
  responseSuccess.setSchemaName(studyInfoObject.getSchema());
  response=new ResponseEntity(responseSuccess,org.springframework.http.HttpStatus.OK);
  return response;
}

Fixed version (ground truth):
private ResponseEntity<Object> processStudyAsync(HttpServletRequest request,String validation_passed_message,Study study,UserAccountBean ownerUserAccount) throws Exception {
  ResponseEntity<Object> response;
  Locale locale=new Locale("String_Node_Str");
  request.getSession().setAttribute(LocaleResolver.getLocaleSessionAttributeName(),locale);
  ResourceBundleProvider.updateLocale(locale);
  StudyInfoObject studyInfoObject=studyBuildService.process(request,study,ownerUserAccount);
  AsyncStudyHelper asyncStudyHelper=new AsyncStudyHelper("String_Node_Str","String_Node_Str");
  AsyncStudyHelper.put(study.getUniqueIdentifier(),asyncStudyHelper);
  liquibaseOnDemandService.createForeignTables(studyInfoObject);
  Study schemaStudy=liquibaseOnDemandService.process(studyInfoObject,studyInfoObject.getUb());
  logger.debug("String_Node_Str" + schemaStudy.getStudyId());
  logger.debug("String_Node_Str" + schemaStudy.getOc_oid());
  ResponseSuccessStudyDTO responseSuccess=new ResponseSuccessStudyDTO();
  responseSuccess.setMessage(validation_passed_message);
  responseSuccess.setStudyOid(schemaStudy.getOc_oid());
  responseSuccess.setUniqueStudyID(schemaStudy.getUniqueIdentifier());
  responseSuccess.setSchemaName(studyInfoObject.getSchema());
  response=new ResponseEntity(responseSuccess,org.springframework.http.HttpStatus.OK);
  return response;
}
Program: 115029
Project: 115029
Buggy source:
UserAccountBean isCallbackSuccessful(HttpServletRequest request,Auth0User user) throws Exception ;

Fixed version (ground truth):
UserAccountHelper isCallbackSuccessful(HttpServletRequest request,Auth0User user) throws Exception ;
Program: 115030
Project: 115030
Buggy source:
@Override public UserAccountBean isCallbackSuccessful(HttpServletRequest request,Auth0User user) throws Exception {
  UserAccountDAO userAccountDAO=new UserAccountDAO(dataSource);
  String _username=user.getNickname();
  logger.info("String_Node_Str" + _username);
  if (StringUtils.isEmpty(_username))   return null;
  UserAccountBean ub=(UserAccountBean)userAccountDAO.findByUserUuid(user.getUserId());
  if (StringUtils.isEmpty(ub.getName())) {
    ub=(UserAccountBean)userAccountDAO.findByUserName(_username);
  }
 else {
    ub.setName(_username);
    userAccountDAO.update(ub);
    updateStudyUsername(ub,user);
  }
  if (ub.getId() == 0) {
    ub=createUserAccount(request,user);
  }
  updateStudyUserRoles(request,ub,user);
  return ub;
}

Fixed version (ground truth):
@Override public UserAccountHelper isCallbackSuccessful(HttpServletRequest request,Auth0User user) throws Exception {
  UserAccountDAO userAccountDAO=new UserAccountDAO(dataSource);
  String _username=user.getNickname();
  logger.info("String_Node_Str" + _username);
  if (StringUtils.isEmpty(_username))   return null;
  UserAccountBean ub=(UserAccountBean)userAccountDAO.findByUserUuid(user.getUserId());
  if (StringUtils.isEmpty(ub.getName())) {
    ub=(UserAccountBean)userAccountDAO.findByUserName(_username);
  }
 else {
    ub.setName(_username);
    userAccountDAO.update(ub);
    updateStudyUsername(ub,user);
  }
  if (ub.getId() == 0) {
    ub=createUserAccount(request,user);
  }
  boolean isUserUpdated=updateStudyUserRoles(request,ub,user);
  return new UserAccountHelper(ub,isUserUpdated);
}
Program: 115031
Project: 115031
Buggy source:
@Modifying private void updateStudyUserRoles(HttpServletRequest request,UserAccountBean ub,Auth0User user) throws Exception {
  Map<String,Object> appMetadata=user.getAppMetadata();
  Object userContext=appMetadata.get("String_Node_Str");
  String toJson=objectMapper.writeValueAsString(userContext);
  Map<String,Object> userContextMap=objectMapper.readValue(toJson,Map.class);
  request.getSession().setAttribute("String_Node_Str",userContextMap);
  studyBuildService.saveStudyEnvRoles(request,ub);
}

Fixed version (ground truth):
@Modifying private boolean updateStudyUserRoles(HttpServletRequest request,UserAccountBean ub,Auth0User user) throws Exception {
  Map<String,Object> appMetadata=user.getAppMetadata();
  Object userContext=appMetadata.get("String_Node_Str");
  String toJson=objectMapper.writeValueAsString(userContext);
  Map<String,Object> userContextMap=objectMapper.readValue(toJson,Map.class);
  request.getSession().setAttribute("String_Node_Str",userContextMap);
  return studyBuildService.saveStudyEnvRoles(request,ub);
}
Program: 115032
Project: 115032
Buggy source:
void saveStudyEnvRoles(HttpServletRequest request,UserAccountBean ub) throws Exception ;

Fixed version (ground truth):
boolean saveStudyEnvRoles(HttpServletRequest request,UserAccountBean ub) throws Exception ;
Program: 115036
Project: 115036
Buggy source:
@Bean @DependsOn("String_Node_Str") public OCCommonTablesSpringLiquibase liquibaseSchemaCommonTables(){
  OCCommonTablesSpringLiquibase liquibase=new OCCommonTablesSpringLiquibase();
  liquibase.setDataSource(dataSource);
  liquibase.setDefaultSchema("String_Node_Str");
  List<String> schemas=new ArrayList<>();
  schemas.add("String_Node_Str");
  liquibase.setSchemas(schemas);
  liquibase.setChangeLog("String_Node_Str");
  return liquibase;
}

Fixed version (ground truth):
@Bean @DependsOn("String_Node_Str") public OCCommonTablesSpringLiquibase liquibaseSchemaCommonTables(){
  OCCommonTablesSpringLiquibase liquibase=new OCCommonTablesSpringLiquibase();
  liquibase.setDataSource(dataSource);
  liquibase.setDefaultSchema("String_Node_Str");
  liquibase.setChangeLog("String_Node_Str");
  return liquibase;
}
Program: 115037
Project: 115037
Buggy source:
public void processSchemaLiquibase() throws LiquibaseException {
  Liquibase liquibase=null;
  if (schemas == null) {
    schemas=new ArrayList<>();
    schemas.add("String_Node_Str");
  }
  for (  String schema : schemas) {
    Connection c=null;
    try {
      c=dataSource.getConnection();
      setDefaultSchema(schema);
      c.setSchema(schema);
      liquibase=createLiquibase(c);
      performUpdate(liquibase);
    }
 catch (    Exception e) {
      throw new LiquibaseException(e);
    }
 finally {
      if (c != null) {
        try {
          c.rollback();
          c.close();
        }
 catch (        SQLException e) {
        }
      }
    }
  }
}

Fixed version (ground truth):
public void processSchemaLiquibase(List<String> schemas) throws LiquibaseException {
  Liquibase liquibase=null;
  if (schemas == null) {
    schemas=new ArrayList<>();
    schemas.add("String_Node_Str");
  }
  for (  String schema : schemas) {
    Connection c=null;
    try {
      c=dataSource.getConnection();
      setDefaultSchema(schema);
      c.setSchema(schema);
      liquibase=createLiquibase(c);
      performUpdate(liquibase);
    }
 catch (    Exception e) {
      throw new LiquibaseException(e);
    }
 finally {
      if (c != null) {
        try {
          c.rollback();
          c.close();
        }
 catch (        SQLException e) {
        }
      }
    }
  }
}