nus-yam/ex-repair huggingface dataset:
Program: 165442
Project: 165442
Buggy source:
private static void runFileNameCleanup(String[] optionValues){
  for (  String fileName : optionValues) {
    File currentFile=new File(fileName);
    if (!currentFile.exists()) {
      System.err.println(currentFile + "String_Node_Str");
    }
 else {
      try {
        WebReleaseRenamer renamer=new WebReleaseRenamer();
        File newFile=renamer.newFileName(currentFile);
        boolean renameStatus=currentFile.renameTo(newFile);
        if (renameStatus != true)         System.err.println("String_Node_Str");
 else         System.out.println("String_Node_Str" + currentFile + "String_Node_Str"+ newFile);
      }
 catch (      IOException e) {
        e.printStackTrace();
      }
    }
  }
}

Fixed version (ground truth):
private static void runFileNameCleanup(String[] optionValues){
  for (  String fileName : optionValues) {
    File currentFile=new File(fileName);
    if (!currentFile.exists()) {
      System.err.println(currentFile + "String_Node_Str");
    }
 else {
      try {
        WebReleaseRenamer renamer=new WebReleaseRenamer();
        File newFile=renamer.newFileName(currentFile);
        boolean renameStatus=currentFile.renameTo(newFile);
        if (renameStatus)         System.out.println("String_Node_Str" + currentFile + "String_Node_Str"+ newFile);
 else         System.err.println("String_Node_Str");
      }
 catch (      IOException e) {
        e.printStackTrace();
      }
    }
  }
}
Program: 165444
Project: 165444
Buggy source:
@Override public void valueChanged(ListSelectionEvent e){
  if (e.getValueIsAdjusting() == false) {
    if (this.guiMain.getFileList().getSelectedIndex() == -1) {
      this.guiMain.removeOldSelectedFileReferences();
    }
 else {
      try {
        guiMain.getFrmMoviescraper().setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
        handleNewSelection();
      }
  finally {
        guiMain.getFrmMoviescraper().setCursor(Cursor.getDefaultCursor());
      }
    }
  }
}

Fixed version (ground truth):
@Override public void valueChanged(ListSelectionEvent e){
  if (!e.getValueIsAdjusting()) {
    if (this.guiMain.getFileList().getSelectedIndex() == -1) {
      this.guiMain.removeOldSelectedFileReferences();
    }
 else {
      try {
        guiMain.getFrmMoviescraper().setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
        handleNewSelection();
      }
  finally {
        guiMain.getFrmMoviescraper().setCursor(Cursor.getDefaultCursor());
      }
    }
  }
}
Program: 165445
Project: 165445
Buggy source:
public static void renameToCleanName(File fileToRename,ReleaseRenamer releaseRenamerToUse){
  File newFileName=releaseRenamerToUse.newFileName(fileToRename);
  boolean renameStatus=fileToRename.renameTo(newFileName);
  if (renameStatus != true)   System.err.println("String_Node_Str" + fileToRename.toString());
}

Fixed version (ground truth):
public static void renameToCleanName(File fileToRename,ReleaseRenamer releaseRenamerToUse){
  File newFileName=releaseRenamerToUse.newFileName(fileToRename);
  boolean renameStatus=fileToRename.renameTo(newFileName);
  if (!renameStatus)   System.err.println("String_Node_Str" + fileToRename.toString());
}
Program: 165446
Project: 165446
Buggy source:
/** 
 * If your file is called "Movie Name Here (2001)" this method returns "2001"
 * @param file the file to process
 * @return A length 4 string representing the year, if it exists. Otherwise an empty String
 */
public static String getYearFromFileWithYear(File file){
  String movieName=FilenameUtils.removeExtension(FilenameUtils.getName(file.getName()));
  String patternString="String_Node_Str";
  Pattern pattern=Pattern.compile(patternString);
  Matcher matcher=pattern.matcher(movieName);
  while (matcher.find()) {
    return matcher.group().replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str").trim();
  }
  return "String_Node_Str";
}

Fixed version (ground truth):
/** 
 * If your file is called "Movie Name Here (2001)" this method returns "2001"
 * @param file the file to process
 * @return A length 4 string representing the year, if it exists. Otherwise an empty String
 */
public static String getYearFromFileWithYear(File file){
  String movieName=FilenameUtils.removeExtension(FilenameUtils.getName(file.getName()));
  String patternString="String_Node_Str";
  Pattern pattern=Pattern.compile(patternString);
  Matcher matcher=pattern.matcher(movieName);
  if (matcher.find()) {
    return matcher.group().replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str").trim();
  }
  return "String_Node_Str";
}
Program: 165447
Project: 165447
Buggy source:
public void setShowToolbar(boolean preferenceValue){
  setBooleanValue(Key.showToolbar,new Boolean(preferenceValue));
}

Fixed version (ground truth):
public void setShowToolbar(boolean preferenceValue){
  setBooleanValue(Key.showToolbar,Boolean.valueOf(preferenceValue));
}
Program: 165449
Project: 165449
Buggy source:
@Override public String createSearchString(File file){
  scrapedMovieFile=file;
  String fileBaseName;
  if (file.isFile())   fileBaseName=FilenameUtils.getBaseName(file.getName());
 else   fileBaseName=file.getName();
  fileBaseName=fileBaseName.replaceFirst("String_Node_Str","String_Node_Str");
  fileName=fileBaseName;
  String[] splitBySpace=fileBaseName.split("String_Node_Str");
  if (splitBySpace.length > 1) {
    if (splitBySpace[splitBySpace.length - 1].matches("String_Node_Str")) {
      yearFromFilename=splitBySpace[splitBySpace.length - 1].replaceAll("String_Node_Str","String_Node_Str");
      fileBaseName=fileBaseName.replaceFirst("String_Node_Str","String_Node_Str").trim();
    }
  }
  if (useSiteSearch) {
    URLCodec codec=new URLCodec();
    try {
      fileBaseName=codec.encode(fileBaseName);
    }
 catch (    EncoderException e) {
      e.printStackTrace();
    }
    fileBaseName="String_Node_Str" + fileBaseName;
    return fileBaseName;
  }
  return FilenameUtils.getBaseName(file.getName());
}

Fixed version (ground truth):
@Override public String createSearchString(File file){
  scrapedMovieFile=file;
  String fileBaseName;
  String yearFromFilename="String_Node_Str";
  if (file.isFile())   fileBaseName=FilenameUtils.getBaseName(file.getName());
 else   fileBaseName=file.getName();
  fileBaseName=fileBaseName.replaceFirst("String_Node_Str","String_Node_Str");
  fileName=fileBaseName;
  String[] splitBySpace=fileBaseName.split("String_Node_Str");
  if (splitBySpace.length > 1) {
    if (splitBySpace[splitBySpace.length - 1].matches("String_Node_Str")) {
      yearFromFilename=splitBySpace[splitBySpace.length - 1].replaceAll("String_Node_Str","String_Node_Str");
      fileBaseName=fileBaseName.replaceFirst("String_Node_Str","String_Node_Str").trim();
    }
  }
  if (useSiteSearch) {
    URLCodec codec=new URLCodec();
    try {
      fileBaseName=codec.encode(fileBaseName);
    }
 catch (    EncoderException e) {
      e.printStackTrace();
    }
    fileBaseName="String_Node_Str" + fileBaseName;
    return fileBaseName;
  }
  return FilenameUtils.getBaseName(file.getName());
}
Program: 165450
Project: 165450
Buggy source:
@Override protected BufferedImage doInBackground() throws IOException {
  if (ImageCache.isImageCached(url,isImageModified)) {
    pictureLoaded=Thumb.convertToBufferedImage(ImageCache.getImageFromCache(url,isImageModified,referrerURL));
  }
 else {
    try {
      URLConnection imageConnection=url.openConnection();
      imageConnection.setRequestProperty("String_Node_Str","String_Node_Str");
      if (referrerURL != null) {
        imageConnection.setRequestProperty("String_Node_Str",referrerURL.toString());
      }
      pictureLoaded=ImageIO.read(imageConnection.getInputStream());
    }
 catch (    Throwable t) {
      System.out.println("String_Node_Str" + t.getMessage());
    }
    if (isImageModified) {
      pictureLoaded=Thumb.convertToBufferedImage(pictureLoaded);
    }
    ImageCache.putImageInCache(url,pictureLoaded,isImageModified);
  }
  return pictureLoaded;
}

Fixed version (ground truth):
@Override protected BufferedImage doInBackground() throws IOException {
  if (url == null) {
    return null;
  }
  if (ImageCache.isImageCached(url,isImageModified)) {
    pictureLoaded=Thumb.convertToBufferedImage(ImageCache.getImageFromCache(url,isImageModified,referrerURL));
  }
 else {
    try {
      URLConnection imageConnection=url.openConnection();
      imageConnection.setRequestProperty("String_Node_Str","String_Node_Str");
      if (referrerURL != null) {
        imageConnection.setRequestProperty("String_Node_Str",referrerURL.toString());
      }
      pictureLoaded=ImageIO.read(imageConnection.getInputStream());
    }
 catch (    Throwable t) {
      System.out.println("String_Node_Str" + t.getMessage());
    }
    if (isImageModified) {
      pictureLoaded=Thumb.convertToBufferedImage(pictureLoaded);
    }
    ImageCache.putImageInCache(url,pictureLoaded,isImageModified);
  }
  return pictureLoaded;
}
Program: 165452
Project: 165452
Buggy source:
public void updateProgressViewWithScrapeFinished(Movie movieThatScraped){
  progressButton.setText("String_Node_Str");
  progressButton.setEnabled(false);
  if (movieThatScraped != null && movieThatScraped.hasValidTitle()) {
  }
}

Fixed version (ground truth):
public void updateProgressViewWithScrapeFinished(Movie movieThatScraped){
  progressButton.setText("String_Node_Str");
  progressButton.setEnabled(false);
}
Program: 165453
Project: 165453
Buggy source:
@Test public void testRuntime(){
  Runtime runtime=profile.scrapeRuntime();
  System.out.println("String_Node_Str" + runtime.getRuntime());
}

Fixed version (ground truth):
public void testRuntime(){
  Runtime runtime=profile.scrapeRuntime();
  System.out.println("String_Node_Str" + runtime.getRuntime());
}
Program: 165454
Project: 165454
Buggy source:
@Test public void testExtraFanart() throws IOException {
  Thumb[] extraFanart=profile.scrapeExtraFanart();
}

Fixed version (ground truth):
@Test public void testExtraFanart() throws IOException {
  Thumb[] extraFanart=profile.scrapeExtraFanart();
  assertTrue("String_Node_Str",extraFanart.length == 10);
}
Program: 165455
Project: 165455
Buggy source:
public static URL getReferrerURLFromImageURL(URL url){
  if (url != null && url.toString().endsWith("String_Node_Str")) {
    int indexOfLastSlash=url.toString().lastIndexOf('/');
    if (indexOfLastSlash > 0) {
      String tempUrlString=url.toString().substring(0,indexOfLastSlash);
      String imageNumber=url.toString().substring(indexOfLastSlash);
      if (imageNumber != null && imageNumber.endsWith("String_Node_Str") && imageNumber.length() > 5) {
        imageNumber=imageNumber.substring(1,imageNumber.length() - 4);
      }
      int indexOfSecondToLastSlash=tempUrlString.toString().lastIndexOf('/');
      if (indexOfSecondToLastSlash > 0 && tempUrlString.length() > 1) {
        String contentID=tempUrlString.substring(indexOfSecondToLastSlash + 1);
        URL referrerURL;
        try {
          referrerURL=new URL("String_Node_Str" + "String_Node_Str" + contentID + "String_Node_Str"+ imageNumber);
          return referrerURL;
        }
 catch (        MalformedURLException e) {
          e.printStackTrace();
        }
      }
    }
  }
  return url;
}

Fixed version (ground truth):
public static URL getReferrerURLFromImageURL(URL url){
  if (url != null && url.toString().endsWith("String_Node_Str")) {
    int indexOfLastSlash=url.toString().lastIndexOf('/');
    if (indexOfLastSlash > 0) {
      String tempUrlString=url.toString().substring(0,indexOfLastSlash);
      String imageNumber=url.toString().substring(indexOfLastSlash);
      if (imageNumber != null && imageNumber.endsWith("String_Node_Str") && imageNumber.length() > 5) {
        imageNumber=imageNumber.substring(1,imageNumber.length() - 4);
      }
      int indexOfSecondToLastSlash=tempUrlString.lastIndexOf('/');
      if (indexOfSecondToLastSlash > 0 && tempUrlString.length() > 1) {
        String contentID=tempUrlString.substring(indexOfSecondToLastSlash + 1);
        URL referrerURL;
        try {
          referrerURL=new URL("String_Node_Str" + "String_Node_Str" + contentID + "String_Node_Str"+ imageNumber);
          return referrerURL;
        }
 catch (        MalformedURLException e) {
          e.printStackTrace();
        }
      }
    }
  }
  return url;
}
Program: 165456
Project: 165456
Buggy source:
@Override public String createSearchString(File file){
  scrapedMovieFile=file;
  String baseId=findIDTagFromFile(file,isFirstWordOfFileIsID()).replace("String_Node_Str","String_Node_Str");
  Pattern patternID=Pattern.compile("String_Node_Str");
  Matcher matcher=patternID.matcher(baseId);
  String groupOne="String_Node_Str";
  String groupTwo="String_Node_Str";
  while (matcher.find()) {
    groupOne=matcher.group(1);
    groupTwo=matcher.group(2);
  }
  if (groupOne == null || groupOne.isEmpty() || groupTwo == null || groupTwo.isEmpty())   return null;
  int number=Integer.parseInt(groupTwo);
  if (groupOne.toUpperCase().equals("String_Node_Str")) {
    return String.format("String_Node_Str",groupOne,number);
  }
  return String.format("String_Node_Str",groupOne,number);
}

Fixed version (ground truth):
@Override public String createSearchString(File file){
  scrapedMovieFile=file;
  String baseId=findIDTagFromFile(file,isFirstWordOfFileIsID()).replace("String_Node_Str","String_Node_Str");
  Pattern patternID=Pattern.compile("String_Node_Str");
  Matcher matcher=patternID.matcher(baseId);
  String groupOne="String_Node_Str";
  String groupTwo="String_Node_Str";
  while (matcher.find()) {
    groupOne=matcher.group(1);
    groupTwo=matcher.group(2);
  }
  if (groupOne == null || groupOne.isEmpty() || groupTwo == null || groupTwo.isEmpty())   return null;
  int number=Integer.parseInt(groupTwo);
  if (groupOne.equalsIgnoreCase("String_Node_Str")) {
    return String.format("String_Node_Str",groupOne,number);
  }
  return String.format("String_Node_Str",groupOne,number);
}
Program: 165457
Project: 165457
Buggy source:
@Override public Icon getIcon(File iconType) throws IOException {
  if (iconType.isDirectory())   return FileSystemView.getFileSystemView().getSystemIcon(iconType);
  String name=FilenameUtils.getName(iconType.getName());
  String ext=FilenameUtils.getExtension(iconType.getName());
  if (ext != "String_Node_Str" && !name.startsWith("String_Node_Str")) {
    String mimeType=Files.probeContentType(iconType.toPath());
    if (mimeType != null) {
      for (      String type : new String[]{"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"})       if (mimeType.startsWith(type + "String_Node_Str"))       return createIcon(type);
    }
  }
  return createIcon("String_Node_Str");
}

Fixed version (ground truth):
@Override public Icon getIcon(File iconType) throws IOException {
  if (iconType.isDirectory())   return FileSystemView.getFileSystemView().getSystemIcon(iconType);
  String name=FilenameUtils.getName(iconType.getName());
  String ext=FilenameUtils.getExtension(iconType.getName());
  if ("String_Node_Str".equals(ext) && !name.startsWith("String_Node_Str")) {
    String mimeType=Files.probeContentType(iconType.toPath());
    if (mimeType != null) {
      for (      String type : new String[]{"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"})       if (mimeType.startsWith(type + "String_Node_Str"))       return createIcon(type);
    }
  }
  return createIcon("String_Node_Str");
}
Program: 165458
Project: 165458
Buggy source:
private boolean allowedSuffix(String suffix){
  for (  String currentSuffix : acceptedMovieExtensions) {
    if (suffix.toLowerCase().equals(currentSuffix))     return true;
  }
  return false;
}

Fixed version (ground truth):
private boolean allowedSuffix(String suffix){
  for (  String currentSuffix : acceptedMovieExtensions) {
    if (suffix.equalsIgnoreCase(currentSuffix))     return true;
  }
  return false;
}
Program: 165459
Project: 165459
Buggy source:
private void tweakLookAndFeel(JToolBar toolbar){
  if (UIManager.getLookAndFeel().getID() == "String_Node_Str") {
    MouseListener hoverListener=new MouseListener(){
      @Override public void mouseExited(      MouseEvent arg0){
        ((JButton)arg0.getSource()).setBorderPainted(false);
      }
      @Override public void mouseEntered(      MouseEvent arg0){
        ((JButton)arg0.getSource()).setBorderPainted(true);
      }
      @Override public void mouseClicked(      MouseEvent arg0){
      }
      @Override public void mouseReleased(      MouseEvent arg0){
      }
      @Override public void mousePressed(      MouseEvent arg0){
      }
    }
;
    for (    Component comp : toolbar.getComponents()) {
      if (comp instanceof JButton) {
        JButton button=(JButton)comp;
        button.setBorderPainted(false);
        button.addMouseListener(hoverListener);
      }
    }
    toolbar.setBackground(new Color(toolbar.getBackground().getRGB()));
    toolbar.setBorderPainted(false);
  }
 else   if (UIManager.getLookAndFeel().getID() == "String_Node_Str") {
    toolbar.setBorder(BorderFactory.createLineBorder(getBackground()));
  }
}

Fixed version (ground truth):
private void tweakLookAndFeel(JToolBar toolbar){
  if ("String_Node_Str".equals(UIManager.getLookAndFeel().getID())) {
    MouseListener hoverListener=new MouseListener(){
      @Override public void mouseExited(      MouseEvent arg0){
        ((JButton)arg0.getSource()).setBorderPainted(false);
      }
      @Override public void mouseEntered(      MouseEvent arg0){
        ((JButton)arg0.getSource()).setBorderPainted(true);
      }
      @Override public void mouseClicked(      MouseEvent arg0){
      }
      @Override public void mouseReleased(      MouseEvent arg0){
      }
      @Override public void mousePressed(      MouseEvent arg0){
      }
    }
;
    for (    Component comp : toolbar.getComponents()) {
      if (comp instanceof JButton) {
        JButton button=(JButton)comp;
        button.setBorderPainted(false);
        button.addMouseListener(hoverListener);
      }
    }
    toolbar.setBackground(new Color(toolbar.getBackground().getRGB()));
    toolbar.setBorderPainted(false);
  }
 else   if ("String_Node_Str".equals(UIManager.getLookAndFeel().getID())) {
    toolbar.setBorder(BorderFactory.createLineBorder(getBackground()));
  }
}
Program: 165462
Project: 165462
Buggy source:
private String getRenamedFolderPath(String path){
  System.out.println("String_Node_Str" + path);
  String newPath=replace(folderNameRenameString);
  String doublePathSeperator=File.separator + File.separator;
  while (newPath.contains(doublePathSeperator)) {
    newPath=newPath.replace(doublePathSeperator,File.separator);
  }
  System.out.println("String_Node_Str" + newPath);
  return newPath;
}

Fixed version (ground truth):
private String getRenamedFolderPath(String path){
  System.out.println("String_Node_Str" + path);
  String newPath=replace(folderNameRenameString);
  String doublePathSeperator=File.separator + File.separator;
  String cutPath="String_Node_Str";
  if (newPath.startsWith(doublePathSeperator)) {
    cutPath=doublePathSeperator;
    newPath=path.substring(2,path.length());
  }
  while (newPath.contains(doublePathSeperator)) {
    newPath=newPath.replace(doublePathSeperator,File.separator);
  }
  newPath=cutPath + newPath;
  System.out.println("String_Node_Str" + newPath);
  return newPath;
}
Program: 165464
Project: 165464
Buggy source:
private void updatePosterAndFanartSizes(){
  updatingPosterAndFanartSizes=true;
  BufferedImage fanartImg=(BufferedImage)(fanartImage);
  if (fanartImg != null) {
    BufferedImage fanartScaledImage=ArtWorkPanel.resizeToFanart(fanartImg);
    this.setNewFanart(fanartScaledImage,false);
  }
  BufferedImage posterImg=Thumb.convertToBufferedImage(posterImage);
  BufferedImage posterScaledImage=ArtWorkPanel.resizeToPoster(posterImg);
  this.setNewPoster(posterScaledImage,false);
}

Fixed version (ground truth):
private void updatePosterAndFanartSizes(){
  updatingPosterAndFanartSizes=true;
  BufferedImage bufferedFanartImg=Thumb.convertToBufferedImage(fanartImage);
  if (bufferedFanartImg != null) {
    BufferedImage fanartScaledImage=ArtWorkPanel.resizeToFanart(bufferedFanartImg);
    this.setNewFanart(fanartScaledImage,false);
  }
  BufferedImage posterImg=Thumb.convertToBufferedImage(posterImage);
  BufferedImage posterScaledImage=ArtWorkPanel.resizeToPoster(posterImg);
  this.setNewPoster(posterScaledImage,false);
}
Program: 165467
Project: 165467
Buggy source:
/** 
 * @param parsingProfile - item to check if scraping is enabled for this parsing profile
 * @return true if scraper should scrape for parsingProfile, false otherwise
 */
protected boolean shouldScrapeThread(DataItemSource parsingProfile){
  for (  ScraperGroupName currentName : ScraperGroupName.values()) {
    ScraperGroupAmalgamationPreference currentPref=this.guiMain.getAllAmalgamationOrderingPreferences().getScraperGroupAmalgamationPreference(currentName);
    LinkedList<DataItemSource> overallPrefs=currentPref.getOverallAmalgamationPreference().getAmalgamationPreferenceOrder();
    for (    DataItemSource currentDataItemSource : overallPrefs) {
      System.out.println("String_Node_Str" + currentDataItemSource.getDataItemSourceName() + "String_Node_Str"+ currentDataItemSource.isDisabled()+ "String_Node_Str"+ parsingProfile.getDataItemSourceName());
      if (currentDataItemSource.getDataItemSourceName().equals(parsingProfile.getDataItemSourceName())) {
        boolean disabled=currentDataItemSource.isDisabled();
        return !disabled;
      }
    }
  }
  return false;
}

Fixed version (ground truth):
/** 
 * @param parsingProfile - item to check if scraping is enabled for this parsing profile
 * @return true if scraper should scrape for parsingProfile, false otherwise
 */
protected boolean shouldScrapeThread(DataItemSource parsingProfile){
  for (  ScraperGroupName currentName : ScraperGroupName.values()) {
    ScraperGroupAmalgamationPreference currentPref=this.guiMain.getAllAmalgamationOrderingPreferences().getScraperGroupAmalgamationPreference(currentName);
    LinkedList<DataItemSource> overallPrefs=currentPref.getOverallAmalgamationPreference().getAmalgamationPreferenceOrder();
    for (    DataItemSource currentDataItemSource : overallPrefs) {
      if (currentDataItemSource.getDataItemSourceName().equals(parsingProfile.getDataItemSourceName())) {
        boolean disabled=currentDataItemSource.isDisabled();
        return !disabled;
      }
    }
  }
  return false;
}
Program: 165470
Project: 165470
Buggy source:
private String renameReplaceAll(String replacementString,String tagName,String movieContentOfTag){
  String replacedString=replacementString;
  if (replacedString.contains(tagName))   replacedString=replacedString.replaceAll(tagName,movieContentOfTag);
  if (movieContentOfTag == null || movieContentOfTag.trim().equals("String_Node_Str")) {
    replacedString=replacedString.replaceAll("String_Node_Str","String_Node_Str");
  }
  return replacedString;
}

Fixed version (ground truth):
private String renameReplaceAll(String replacementString,String tagName,String movieContentOfTag){
  String replacedString=replacementString;
  if (replacedString.contains(tagName)) {
    replacedString=StringUtils.replace(replacedString,tagName,movieContentOfTag);
  }
  if (movieContentOfTag == null || movieContentOfTag.trim().equals("String_Node_Str")) {
    replacedString=replacedString.replaceAll("String_Node_Str","String_Node_Str");
  }
  return replacedString;
}
Program: 165471
Project: 165471
Buggy source:
@Override public Year scrapeYear(){
  Element releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null & releaseDateElement.text().contains("String_Node_Str"))   releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null) {
    String releaseDateText=releaseDateElement.text().trim();
    if (releaseDateText.length() >= 4) {
      releaseDateText=releaseDateText.substring(releaseDateText.length() - 4,releaseDateText.length());
      return new Year(releaseDateText);
    }
  }
  return Year.BLANK_YEAR;
}

Fixed version (ground truth):
@Override public Year scrapeYear(){
  return scrapeReleaseDate().getYear();
}
Program: 165472
Project: 165472
Buggy source:
@Override public ReleaseDate scrapeReleaseDate(){
  Element releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null & releaseDateElement.text().contains("String_Node_Str"))   releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null) {
    String releaseDateText=releaseDateElement.text().trim();
    if (releaseDateText.length() > 4) {
      return new ReleaseDate(releaseDateText,data18ReleaseDateFormat);
    }
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}

Fixed version (ground truth):
@Override public ReleaseDate scrapeReleaseDate(){
  SimpleDateFormat dateFormatToUse=data18ReleaseDateFormat;
  Element releaseDateElement=document.select("String_Node_Str").first();
  if ((releaseDateElement != null && releaseDateElement.text() != null && releaseDateElement.text().contains("String_Node_Str")) || releaseDateElement == null) {
    releaseDateElement=document.select("String_Node_Str").first();
    dateFormatToUse=new SimpleDateFormat("String_Node_Str");
  }
  System.out.println("String_Node_Str" + releaseDateElement);
  if (releaseDateElement != null) {
    String releaseDateText=releaseDateElement.text().trim();
    if (releaseDateText.length() > 4) {
      return new ReleaseDate(releaseDateText,dateFormatToUse);
    }
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}
Program: 165474
Project: 165474
Buggy source:
private void updatePosterAndFanartSizes(){
  updatingPosterAndFanartSizes=true;
  BufferedImage fanartImg=(BufferedImage)(fanartImage);
  if (fanartImg != null) {
    BufferedImage fanartScaledImage=ArtWorkPanel.resizeToFanart(fanartImg);
    this.setNewFanart(fanartScaledImage,false);
  }
  BufferedImage posterImg=(BufferedImage)(posterImage);
  BufferedImage posterScaledImage=ArtWorkPanel.resizeToPoster(posterImg);
  this.setNewPoster(posterScaledImage,false);
}

Fixed version (ground truth):
private void updatePosterAndFanartSizes(){
  updatingPosterAndFanartSizes=true;
  BufferedImage fanartImg=(BufferedImage)(fanartImage);
  if (fanartImg != null) {
    BufferedImage fanartScaledImage=ArtWorkPanel.resizeToFanart(fanartImg);
    this.setNewFanart(fanartScaledImage,false);
  }
  BufferedImage posterImg=Thumb.convertToBufferedImage(posterImage);
  BufferedImage posterScaledImage=ArtWorkPanel.resizeToPoster(posterImg);
  this.setNewPoster(posterScaledImage,false);
}
Program: 165475
Project: 165475
Buggy source:
@Override public ReleaseDate scrapeReleaseDate(){
  SimpleDateFormat dateFormatToUse=data18ReleaseDateFormat;
  Element releaseDateElement=document.select("String_Node_Str").first();
  if ((releaseDateElement != null && releaseDateElement.text() != null && releaseDateElement.text().contains("String_Node_Str")) || releaseDateElement == null) {
    releaseDateElement=document.select("String_Node_Str").first();
    dateFormatToUse=new SimpleDateFormat("String_Node_Str");
  }
  if (releaseDateElement != null) {
    String releaseDateText=releaseDateElement.text().trim();
    if (releaseDateText.length() > 4) {
      return new ReleaseDate(releaseDateText,dateFormatToUse);
    }
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}

Fixed version (ground truth):
@Override public ReleaseDate scrapeReleaseDate(){
  SimpleDateFormat dateFormatToUse=data18ReleaseDateFormat;
  Element releaseDateElement=document.select("String_Node_Str").first();
  if ((releaseDateElement != null && releaseDateElement.text() != null && releaseDateElement.text().contains("String_Node_Str")) || releaseDateElement == null) {
    releaseDateElement=document.select("String_Node_Str").first();
    dateFormatToUse=new SimpleDateFormat("String_Node_Str",Locale.ENGLISH);
  }
  if (releaseDateElement != null) {
    String releaseDateText=releaseDateElement.text().trim();
    if (releaseDateText.length() > 4) {
      return new ReleaseDate(releaseDateText,dateFormatToUse);
    }
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}
Program: 165476
Project: 165476
Buggy source:
@Override public ReleaseDate scrapeReleaseDate(){
  Element releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null) {
    ReleaseDate releaseDate=new ReleaseDate(releaseDateElement.text(),new SimpleDateFormat("String_Node_Str"));
    return releaseDate;
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}

Fixed version (ground truth):
@Override public ReleaseDate scrapeReleaseDate(){
  Element releaseDateElement=document.select("String_Node_Str").first();
  if (releaseDateElement != null) {
    ReleaseDate releaseDate=new ReleaseDate(releaseDateElement.text(),new SimpleDateFormat("String_Node_Str",Locale.ENGLISH));
    return releaseDate;
  }
  return ReleaseDate.BLANK_RELEASEDATE;
}
Program: 165477
Project: 165477
Buggy source:
public static void main(String[] args){
  ReleaseDate christmasDay=new ReleaseDate("String_Node_Str");
  System.out.println("String_Node_Str" + christmasDay);
  System.out.println("String_Node_Str" + christmasDay.isReleaseDateFormattedCorrectly());
  System.out.println("String_Node_Str" + christmasDay.getMonth() + "String_Node_Str"+ christmasDay.getYear()+ "String_Node_Str"+ christmasDay.getDay());
  System.out.println("String_Node_Str");
  ReleaseDate newYear=new ReleaseDate("String_Node_Str",new SimpleDateFormat("String_Node_Str"));
  System.out.println(newYear);
}

Fixed version (ground truth):
public static void main(String[] args){
  ReleaseDate christmasDay=new ReleaseDate("String_Node_Str");
  System.out.println("String_Node_Str" + christmasDay);
  System.out.println("String_Node_Str" + christmasDay.isReleaseDateFormattedCorrectly());
  System.out.println("String_Node_Str" + christmasDay.getMonth() + "String_Node_Str"+ christmasDay.getYear()+ "String_Node_Str"+ christmasDay.getDay());
  System.out.println("String_Node_Str");
  ReleaseDate newYear=new ReleaseDate("String_Node_Str",new SimpleDateFormat("String_Node_Str",Locale.ENGLISH));
  System.out.println(newYear);
}
Program: 165478
Project: 165478
Buggy source:
private String renameReplaceAll(String replacementString,String tagName,String movieContentOfTag){
  String replacedString=replacementString;
  if (replacedString.contains(tagName)) {
    replacedString=StringUtils.replace(replacedString,tagName,movieContentOfTag);
  }
  if (movieContentOfTag == null || movieContentOfTag.trim().equals("String_Node_Str")) {
    replacedString=replacedString.replaceAll("String_Node_Str","String_Node_Str");
  }
  return replacedString;
}

Fixed version (ground truth):
private String renameReplaceAll(String replacementString,String tagName,String movieContentOfTag){
  String replacedString=replacementString;
  if (movieContentOfTag == null) {
    replacedString=replacedString.replace(tagName,"String_Node_Str");
  }
  if (replacedString.contains(tagName)) {
    replacedString=StringUtils.replace(replacedString,tagName,movieContentOfTag);
  }
  if (movieContentOfTag == null || movieContentOfTag.trim().equals("String_Node_Str")) {
    replacedString=replacedString.replaceAll("String_Node_Str","String_Node_Str");
  }
  return replacedString;
}
Program: 165480
Project: 165480
Buggy source:
@Override public ArrayList<Genre> scrapeGenres(){
  ArrayList<Genre> genreList=new ArrayList<Genre>();
  Elements genreElements=document.select("String_Node_Str");
  if (genreElements != null) {
    for (    Element currentGenreElement : genreElements) {
      String genreText=currentGenreElement.text().trim();
      if (genreText != null && genreText.length() > 0)       genreList.add(new Genre(genreText));
    }
  }
  return genreList;
}

Fixed version (ground truth):
@Override public ArrayList<Genre> scrapeGenres(){
  ArrayList<Genre> genreList=new ArrayList<Genre>();
  Elements genreElements=document.select("String_Node_Str");
  System.out.println("String_Node_Str" + genreElements);
  if (genreElements != null) {
    for (    Element currentGenreElement : genreElements) {
      String genreText=currentGenreElement.text().trim();
      if (genreText != null && genreText.length() > 0)       genreList.add(new Genre(genreText));
    }
  }
  return genreList;
}
Program: 165482
Project: 165482
Buggy source:
public SelectScrapersDialog(JFrame parent,List<String> options,List<String> selected){
  this.checkboxes=new ArrayList<>();
  this.selected=selected;
  this.panel=Box.createVerticalBox();
  JLabel helpLabel=new JLabel("String_Node_Str");
  Font baseFont=helpLabel.getFont().deriveFont(Font.PLAIN);
  panel.add(helpLabel);
  this.parent=parent;
  for (  String option : options) {
    boolean isSelected=selected.contains(option);
    JCheckBox cb=new JCheckBox(option,isSelected);
    checkboxes.add(cb);
    panel.add(cb);
  }
}

Fixed version (ground truth):
public SelectScrapersDialog(JFrame parent,List<String> options,List<String> selected){
  this.checkboxes=new ArrayList<>();
  this.selected=selected;
  this.panel=Box.createVerticalBox();
  JLabel helpLabel=new JLabel("String_Node_Str");
  panel.add(helpLabel);
  this.parent=parent;
  for (  String option : options) {
    boolean isSelected=selected.contains(option);
    JCheckBox cb=new JCheckBox(option,isSelected);
    checkboxes.add(cb);
    panel.add(cb);
  }
}
Program: 165483
Project: 165483
Buggy source:
public void actionPerformed(ActionEvent arg0){
  for (int movieNumberInList=0; movieNumberInList < this.guiMain.getCurrentlySelectedMovieFileList().size(); movieNumberInList++) {
    if (this.guiMain.getCurrentlySelectedMovieFileList() != null) {
      try {
        Desktop.getDesktop().open(this.guiMain.getCurrentlySelectedMovieFileList().get(movieNumberInList));
      }
 catch (      IOException e) {
        e.printStackTrace();
        JOptionPane.showMessageDialog(null,ExceptionUtils.getStackTrace(e),"String_Node_Str",JOptionPane.ERROR_MESSAGE);
      }
    }
  }
}

Fixed version (ground truth):
public void actionPerformed(ActionEvent arg0){
  for (int movieNumberInList=0; movieNumberInList < this.guiMain.getCurrentlySelectedMovieFileList().size(); movieNumberInList++) {
    if (this.guiMain.getCurrentlySelectedMovieFileList() != null) {
      try {
        if (this.guiMain.getCurrentlySelectedMovieFileList().get(movieNumberInList).exists()) {
          Desktop.getDesktop().open(this.guiMain.getCurrentlySelectedMovieFileList().get(movieNumberInList));
        }
      }
 catch (      IOException e) {
        e.printStackTrace();
      }
    }
  }
}
Program: 165487
Project: 165487
Buggy source:
@Override public ID scrapeID(){
  String baseUri=document.baseUri();
  if (baseUri.length() > 0 && baseUri.contains("String_Node_Str")) {
    baseUri=baseUri.replaceFirst("String_Node_Str","String_Node_Str");
    String idFromBaseUri=baseUri.substring(baseUri.lastIndexOf('/') + 1);
    return new ID(idFromBaseUri);
  }
  return new ID("String_Node_Str");
}

Fixed version (ground truth):
@Override public ID scrapeID(){
  initializeJapaneseDocument();
  String baseUri=japaneseDocument.baseUri();
  if (baseUri.length() > 0 && baseUri.contains("String_Node_Str")) {
    baseUri=baseUri.replaceFirst("String_Node_Str","String_Node_Str");
    String idFromBaseUri=baseUri.substring(baseUri.lastIndexOf('/') + 1);
    return new ID(idFromBaseUri);
  }
  return new ID("String_Node_Str");
}
Program: 165488
Project: 165488
Buggy source:
@Override public ArrayList<Actor> scrapeActors(){
  ArrayList<Actor> actorList=new ArrayList<Actor>();
  initializeJapaneseDocument();
  Element actorEnglishSearchElement=document.select("String_Node_Str").first();
  Elements japaneseActors=japaneseDocument.select("String_Node_Str");
  if (actorEnglishSearchElement != null && getScrapingLanguage() == Language.ENGLISH) {
    String hrefText=actorEnglishSearchElement.attr("String_Node_Str");
    hrefText=hrefText.replaceFirst(Pattern.quote("String_Node_Str"),"String_Node_Str");
    hrefText=hrefText.replaceFirst("String_Node_Str","String_Node_Str");
    try {
      hrefText=URLDecoder.decode(hrefText,"String_Node_Str");
      String[] actorNames=hrefText.split("String_Node_Str");
      for (int i=0; i < actorNames.length; i++) {
        actorList.add(new Actor(actorNames[i],"String_Node_Str",null));
      }
    }
 catch (    UnsupportedEncodingException e) {
      e.printStackTrace();
    }
  }
 else   if (japaneseActors != null && getScrapingLanguage() == Language.JAPANESE) {
    for (    Element japaneseActor : japaneseActors) {
      String actorName=japaneseActor.text();
      actorList.add(new Actor(actorName,"String_Node_Str",null));
    }
  }
  return actorList;
}

Fixed version (ground truth):
@Override public ArrayList<Actor> scrapeActors(){
  ArrayList<Actor> actorList=new ArrayList<Actor>();
  initializeJapaneseDocument();
  Element actorEnglishSearchElement=document.select("String_Node_Str").first();
  Elements japaneseActors=japaneseDocument.select("String_Node_Str");
  if (actorEnglishSearchElement != null && getScrapingLanguage() == Language.ENGLISH) {
    String hrefText=actorEnglishSearchElement.attr("String_Node_Str");
    hrefText=hrefText.replaceFirst(Pattern.quote("String_Node_Str"),"String_Node_Str");
    hrefText=hrefText.replaceFirst("String_Node_Str","String_Node_Str");
    try {
      hrefText=URLDecoder.decode(hrefText,"String_Node_Str");
      String[] actorNames=hrefText.split("String_Node_Str");
      for (int i=0; i < actorNames.length; i++) {
        actorList.add(new Actor(actorNames[i],"String_Node_Str",null));
      }
    }
 catch (    UnsupportedEncodingException e) {
      e.printStackTrace();
    }
  }
 else   if ((japaneseActors != null && getScrapingLanguage() == Language.JAPANESE) || actorList.size() == 0) {
    for (    Element japaneseActor : japaneseActors) {
      String actorName=japaneseActor.text();
      if (scrapingLanguage == Language.ENGLISH)       actorName=TranslateString.translateJapanesePersonNameToRomaji(actorName);
      actorList.add(new Actor(actorName,"String_Node_Str",null));
    }
  }
  return actorList;
}
Program: 165490
Project: 165490
Buggy source:
/** 
 * Launch the application.
 */
public static void main(String[] args){
  EventQueue.invokeLater(new Runnable(){
    public void run(){
      try {
        RenamerGUI frame=new RenamerGUI(new MoviescraperPreferences(),null);
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
      }
 catch (      Exception e) {
        e.printStackTrace();
      }
    }
  }
);
}

Fixed version (ground truth):
/** 
 * Launch the application.
 */
public static void main(String[] args){
  EventQueue.invokeLater(new Runnable(){
    public void run(){
      try {
        RenamerGUI frame=new RenamerGUI(MoviescraperPreferences.getInstance(),null);
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
      }
 catch (      Exception e) {
        e.printStackTrace();
      }
    }
  }
);
}
Program: 165491
Project: 165491
Buggy source:
public void run(){
  try {
    RenamerGUI frame=new RenamerGUI(new MoviescraperPreferences(),null);
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
}

Fixed version (ground truth):
public void run(){
  try {
    RenamerGUI frame=new RenamerGUI(MoviescraperPreferences.getInstance(),null);
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
}
Program: 165492
Project: 165492
Buggy source:
private static void runRename(String[] optionValues){
  for (  String fileName : optionValues) {
    File currentFile=new File(fileName);
    if (!currentFile.exists()) {
      System.err.println(currentFile + "String_Node_Str");
    }
 else {
      System.out.println("String_Node_Str" + currentFile);
      MoviescraperPreferences preferences=new MoviescraperPreferences();
      System.out.println("String_Node_Str");
      System.out.println(preferences);
      try {
        Renamer.rename(currentFile,preferences);
      }
 catch (      IOException e) {
        e.printStackTrace();
      }
    }
  }
}

Fixed version (ground truth):
private static void runRename(String[] optionValues){
  for (  String fileName : optionValues) {
    File currentFile=new File(fileName);
    if (!currentFile.exists()) {
      System.err.println(currentFile + "String_Node_Str");
    }
 else {
      System.out.println("String_Node_Str" + currentFile);
      MoviescraperPreferences preferences=MoviescraperPreferences.getInstance();
      System.out.println("String_Node_Str");
      System.out.println(preferences);
      try {
        Renamer.rename(currentFile,preferences);
      }
 catch (      IOException e) {
        e.printStackTrace();
      }
    }
  }
}
Program: 165493
Project: 165493
Buggy source:
private static void writeMovieToFile(Movie scrapedMovie,File scrapeTarget){
  MoviescraperPreferences preferences=new MoviescraperPreferences();
  File nfoFile=new File(Movie.getFileNameOfNfo(scrapeTarget,preferences.getNfoNamedMovieDotNfo()));
  File posterFile=new File(Movie.getFileNameOfPoster(scrapeTarget,preferences.getNoMovieNameInImageFiles()));
  File fanartFile=new File(Movie.getFileNameOfFanart(scrapeTarget,preferences.getNoMovieNameInImageFiles()));
  File currentlySelectedFolderJpgFile=new File(Movie.getFileNameOfFolderJpg(scrapeTarget));
  File extraFanartFolder=new File(Movie.getFileNameOfExtraFanartFolderName(scrapeTarget));
  File trailerFile=new File(Movie.getFileNameOfTrailer(scrapeTarget));
  try {
    scrapedMovie.writeToFile(nfoFile,posterFile,fanartFile,currentlySelectedFolderJpgFile,extraFanartFolder,trailerFile,preferences);
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}

Fixed version (ground truth):
private static void writeMovieToFile(Movie scrapedMovie,File scrapeTarget){
  MoviescraperPreferences preferences=MoviescraperPreferences.getInstance();
  File nfoFile=new File(Movie.getFileNameOfNfo(scrapeTarget,preferences.getNfoNamedMovieDotNfo()));
  File posterFile=new File(Movie.getFileNameOfPoster(scrapeTarget,preferences.getNoMovieNameInImageFiles()));
  File fanartFile=new File(Movie.getFileNameOfFanart(scrapeTarget,preferences.getNoMovieNameInImageFiles()));
  File currentlySelectedFolderJpgFile=new File(Movie.getFileNameOfFolderJpg(scrapeTarget));
  File extraFanartFolder=new File(Movie.getFileNameOfExtraFanartFolderName(scrapeTarget));
  File trailerFile=new File(Movie.getFileNameOfTrailer(scrapeTarget));
  try {
    scrapedMovie.writeToFile(nfoFile,posterFile,fanartFile,currentlySelectedFolderJpgFile,extraFanartFolder,trailerFile,preferences);
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}
Program: 165494
Project: 165494
Buggy source:
public Movie(SiteParsingProfile siteToScrapeFrom){
  title=siteToScrapeFrom.scrapeTitle();
  originalTitle=siteToScrapeFrom.scrapeOriginalTitle();
  sortTitle=siteToScrapeFrom.scrapeSortTitle();
  set=siteToScrapeFrom.scrapeSet();
  rating=siteToScrapeFrom.scrapeRating();
  year=siteToScrapeFrom.scrapeYear();
  top250=siteToScrapeFrom.scrapeTop250();
  trailer=siteToScrapeFrom.scrapeTrailer();
  votes=siteToScrapeFrom.scrapeVotes();
  outline=siteToScrapeFrom.scrapeOutline();
  plot=siteToScrapeFrom.scrapePlot();
  tagline=siteToScrapeFrom.scrapeTagline();
  studio=siteToScrapeFrom.scrapeStudio();
  runtime=siteToScrapeFrom.scrapeRuntime();
  posters=siteToScrapeFrom.scrapePosters();
  fanart=siteToScrapeFrom.scrapeFanart();
  extraFanart=siteToScrapeFrom.scrapeExtraFanart();
  mpaa=siteToScrapeFrom.scrapeMPAA();
  id=siteToScrapeFrom.scrapeID();
  actors=siteToScrapeFrom.scrapeActors();
  genres=siteToScrapeFrom.scrapeGenres();
  directors=siteToScrapeFrom.scrapeDirectors();
  MoviescraperPreferences scraperPreferences=new MoviescraperPreferences();
  if (scraperPreferences.getAppendIDToStartOfTitle() && id != null && id.getId() != null && id.getId().trim().length() > 0 && title != null && title.getTitle() != null && title.getTitle().length() > 0) {
    title.setTitle(id.getId() + "String_Node_Str" + title.getTitle());
  }
}

Fixed version (ground truth):
public Movie(SiteParsingProfile siteToScrapeFrom){
  title=siteToScrapeFrom.scrapeTitle();
  originalTitle=siteToScrapeFrom.scrapeOriginalTitle();
  sortTitle=siteToScrapeFrom.scrapeSortTitle();
  set=siteToScrapeFrom.scrapeSet();
  rating=siteToScrapeFrom.scrapeRating();
  year=siteToScrapeFrom.scrapeYear();
  top250=siteToScrapeFrom.scrapeTop250();
  trailer=siteToScrapeFrom.scrapeTrailer();
  votes=siteToScrapeFrom.scrapeVotes();
  outline=siteToScrapeFrom.scrapeOutline();
  plot=siteToScrapeFrom.scrapePlot();
  tagline=siteToScrapeFrom.scrapeTagline();
  studio=siteToScrapeFrom.scrapeStudio();
  runtime=siteToScrapeFrom.scrapeRuntime();
  posters=siteToScrapeFrom.scrapePosters();
  fanart=siteToScrapeFrom.scrapeFanart();
  extraFanart=siteToScrapeFrom.scrapeExtraFanart();
  mpaa=siteToScrapeFrom.scrapeMPAA();
  id=siteToScrapeFrom.scrapeID();
  actors=siteToScrapeFrom.scrapeActors();
  genres=siteToScrapeFrom.scrapeGenres();
  directors=siteToScrapeFrom.scrapeDirectors();
  MoviescraperPreferences scraperPreferences=MoviescraperPreferences.getInstance();
  if (scraperPreferences.getAppendIDToStartOfTitle() && id != null && id.getId() != null && id.getId().trim().length() > 0 && title != null && title.getTitle() != null && title.getTitle().length() > 0) {
    title.setTitle(id.getId() + "String_Node_Str" + title.getTitle());
  }
}
Program: 165495
Project: 165495
Buggy source:
public SiteParsingProfile(){
  scrapingLanguage=Language.ENGLISH;
  scrapingPreferences=new MoviescraperPreferences();
  this.firstWordOfFileIsID=scrapingPreferences.getIsFirstWordOfFileID();
}

Fixed version (ground truth):
public SiteParsingProfile(){
  scrapingLanguage=Language.ENGLISH;
  scrapingPreferences=MoviescraperPreferences.getInstance();
  this.firstWordOfFileIsID=scrapingPreferences.getIsFirstWordOfFileID();
}
Program: 165496
Project: 165496
Buggy source:
@Override public SiteParsingProfile newInstance(){
  MoviescraperPreferences preferences=new MoviescraperPreferences();
  return new DmmParsingProfile(preferences.getScrapeInJapanese());
}

Fixed version (ground truth):
@Override public SiteParsingProfile newInstance(){
  MoviescraperPreferences preferences=MoviescraperPreferences.getInstance();
  return new DmmParsingProfile(preferences.getScrapeInJapanese());
}