<commit_before>class TutorProjectsController < ApplicationController
  include TutorProjectsHelper

  before_filter :authenticate_user!
  before_filter :load_current_user

  def show
    @student_projects         = Project.find(@user.team_memberships.map{|membership| membership.project_id })
    @tutor_project_templates  = Team.where(:user_id => @user.id).map{|team| team.project_template }.uniq

    @tutor_teams              = Team.includes(:team_memberships => [{:project => [{:tasks => [:task_template]}]}]).where(:user_id => @user.id, :project_template_id => params[:id])
    @tutor_team_projects      = @tutor_teams.map{|team| team.team_memberships }.flatten.map{|team_membership| team_membership.project }

    @project_template         = ProjectTemplate.find(params[:id])

    @unmarked_tasks           = unmarked_project_tasks(@tutor_team_projects, @user)
  end

  def load_current_user
    @user = current_user
  end
end<commit_msg>Changed TutorProjectsController to call other method used to filter unmarked tasks<commit_after>class TutorProjectsController < ApplicationController
  include TutorProjectsHelper

  before_filter :authenticate_user!
  before_filter :load_current_user

  def show
    @student_projects         = Project.find(@user.team_memberships.map{|membership| membership.project_id })
    @tutor_project_templates  = Team.where(:user_id => @user.id).map{|team| team.project_template }.uniq

    @tutor_teams              = Team.includes(:team_memberships => [{:project => [{:tasks => [:task_template]}]}]).where(:user_id => @user.id, :project_template_id => params[:id])
    @tutor_team_projects      = @tutor_teams.map{|team| team.team_memberships }.flatten.map{|team_membership| team_membership.project }

    @project_template         = ProjectTemplate.find(params[:id])

    @unmarked_tasks           = unmarked_tasks(@tutor_team_projects)
  end

  def load_current_user
    @user = current_user
  end
end
{'fraction_non_alphanumeric': 0.11225540679711637, 'fraction_numerical': 0.0, 'mean_word_length': 4.551428571428572, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6429280', 'n_tokens_mistral': 632, 'n_tokens_neox': 590, 'n_words': 96}