title: Rails newbie, been struggling to solve this syntax error for the past few hours
body: <p>I believe the problem lies in the controller code. </p>
  
  <p>I'm getting the following error:</p>
  
  <pre><code>"app/controllers/places_controller.rb:74: syntax error, unexpected keyword_end, expecting end-of-input"
  </code></pre>
  
  <p>Before, everything was working fine. I ran a migration to have it work with the paperclip gem. I have been following the instructions on the github page. I also updated the models (I commented out the code for the models but still was getting the same error). This leads me to believe, the issue lies in the controller itself. </p>
  
  <p>The funny thing is, the controller was working fine before with the same code, but now it's not. I have attached the full controller code below. </p>
  
  <pre><code>pclass PlacesController &lt; ApplicationController
  before_action :set_place, only: [:show, :edit, :update, :destroy]
  
  # GET /places
  # GET /places.json
  def index
  @places = Place.all
  end
  
  # GET /places/1
  # GET /places/1.json
  def show
  end
  
  # GET /places/new
  def new
  @place = Place.new
  end
  
  # GET /places/1/edit
  def edit
  end
  
  # POST /places
  # POST /places.json
  def create
  @place = Place.new(place_params)
  
  respond_to do |format|
    if @place.save
      format.html { redirect_to @place, notice: 'Place was successfully created.' }
      format.json { render :show, status: :created, location: @place }
    else
      format.html { render :new }
      format.json { render json: @place.errors, status: :unprocessable_entity }
    end
  end
  end
  
  # PATCH/PUT /places/1
  # PATCH/PUT /places/1.json
  def update
  respond_to do |format|
    if @place.update(place_params)
      format.html { redirect_to @place, notice: 'Place was successfully updated.' }
      format.json { render :show, status: :ok, location: @place }
    else
      format.html { render :edit }
      format.json { render json: @place.errors, status: :unprocessable_entity }
    end
   end
  end
  
  # DELETE /places/1
  # DELETE /places/1.json
  def destroy
  @place.destroy
  respond_to do |format|
    format.html { redirect_to places_url, notice: 'Place was successfully destroyed.' }
    format.json { head :no_content }
  end
  end
  
  private
  # Use callbacks to share common setup or constraints between actions.
  def set_place
    @place = Place.find(params[:id])
  end
  
  # Never trust parameters from the scary internet, only allow the white list through.
  def place_params
    params.require(:place).permit(:name, :description, :rating, :images)
  end
  end
  </code></pre>