Fix bug w/ nested attributes
Fix bug w/ nested attributes

In the following specs:

    RSpec.describe "Photo attachments" do
      describe "updating through nested attributes" do
        let(:homepage) { create(:homepage) }
        let(:homepage_speaker) { create(:homepage_speaker, homepage: homepage) }
        let(:photo) { create(:photo) }

        before do
          homepage_speaker.hero_image_attachment.destroy
        end

        it "creates attachment when also setting other attributes" do
          expect {
            homepage.update(
              homepage_speakers_attributes: [{
                id: homepage_speaker.id,
                hero_image_id: photo.id,
                pinned: true
              }]
            )
          }.to change {
            PhotoAttachment.count
          }.by(1)
        end

        it "creates attachment when not setting any other attributes" do
          expect {
            homepage.update(
              homepage_speakers_attributes: [{
                id: homepage_speaker.id,
                hero_image_id: photo.id
              }]
            )
          }.to change {
            PhotoAttachment.count
          }.by(1)
        end
      end
    end

The first would pass, but the second would fail -- it seems that
the method we're using to indicate that a model should be saved
doesn't work in this particular scenario (nested attributes + no
other updates). Resorted to manually updating 'updated_at' to
trigger a resave, which works but doesn't feel great.

vigetlabs/simplest_photo