<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>spitfire_tree</author_name>
  <author_url>https://blog.hatena.ne.jp/spitfire_tree/</author_url>
  <blog_title>happy lie, happy life</blog_title>
  <blog_url>https://spitfire-tree.hatenadiary.org/</blog_url>
  <categories>
    <anon>Rails</anon>
  </categories>
  <description>単一テーブル継承はたまに使いますが、使うたびに何かしら問題が起きる気がします。 class Animal &lt; ActiveRecord::Base end class Dog &lt; Animal end class Cat &lt; Animal end これらのクラスを（実際は色々と問題があるので別ファイルに分けて）実装し Animal.subclasses と書くと [Dog, Cat] が返ってきて欲しいし、実際 production 環境では動作するのですが development 環境で素直に実行すると [] と空の配列が返ってきます。理由は development モードではモデルは都度ロ…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fspitfire-tree.hatenadiary.org%2Fentry%2F20160620%2F1466418715&quot; title=&quot;Rails 4.0 の STI を development モードで使うとサブクラスがロードされない問題 - happy lie, happy life&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2016-06-20 19:31:55</published>
  <title>Rails 4.0 の STI を development モードで使うとサブクラスがロードされない問題</title>
  <type>rich</type>
  <url>https://spitfire-tree.hatenadiary.org/entry/20160620/1466418715</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
