<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -141,7 +141,8 @@
 		function save() {
 			$conn =&amp; _adodb_conn();
 			$this-&gt;set_attributes(array(
-				&quot;type&quot; =&gt; ($this-&gt;_type_name == $this-&gt;_base_class) ? NULL : $this-&gt;_type_name,
+				# FIXME strtolower() needed for PHP4 compatibility, remove it later
+				&quot;type&quot; =&gt; (strtolower($this-&gt;_type_name) == strtolower($this-&gt;_base_class)) ? NULL : $this-&gt;_type_name,
 				&quot;updated_at&quot; =&gt; mktime()
 			));
 </diff>
      <filename>lib/AdoDBRecord.class.php</filename>
    </modified>
    <modified>
      <diff>@@ -121,6 +121,8 @@
 			$find_scope = array();
 			$conditions = array();
 			$create_scope = array();
+			# FIXME PHP4 does not like passing properties by reference (_scoped_methods) of overloaded objects,
+			# fix this after dropping PHP4 support
 			$scoped_methods = $this-&gt;_scoped_methods;
 			foreach($scoped_methods as $scope) {
 				if(isset($scope[&quot;find&quot;])) {</diff>
      <filename>lib/AdoDBRecord/Tools.module.php</filename>
    </modified>
    <modified>
      <diff>@@ -48,15 +48,15 @@
 
 			$stest = new SuperTest(array(&quot;dummy&quot; =&gt; &quot;SuperDummy&quot;));
 			$stest-&gt;save();
-			$this-&gt;assertEqual($stest-&gt;type, &quot;SuperTest&quot;);
+			$this-&gt;assertEqual(strtolower($stest-&gt;type), &quot;supertest&quot;);
 
 			$utest = new UltraTest(array(&quot;dummy&quot; =&gt; &quot;UltraDummy&quot;));
 			$utest-&gt;save();
-			$this-&gt;assertEqual($utest-&gt;type, &quot;UltraTest&quot;);
+			$this-&gt;assertEqual(strtolower($utest-&gt;type), &quot;ultratest&quot;);
 
 			$atest = new AutoTest(array(&quot;dummy&quot; =&gt; &quot;AutoDummy&quot;));
 			$atest-&gt;save();
-			$this-&gt;assertEqual($atest-&gt;type, &quot;AutoTest&quot;);
+			$this-&gt;assertEqual(strtolower($atest-&gt;type), &quot;autotest&quot;);
 
 			# PHP 5.3 needed to call magic methods statically, so
 			# work around by instanciating the class as singleton
@@ -68,15 +68,15 @@
 			$this-&gt;assertEqual(strtolower(get_class($dummy2)), &quot;test&quot;);
 
 			$stest2 = $Test-&gt;find_by_dummy(&quot;SuperDummy&quot;);
-			$this-&gt;assertEqual($stest2-&gt;type, &quot;SuperTest&quot;);
+			$this-&gt;assertEqual(strtolower($stest2-&gt;type), &quot;supertest&quot;);
 			$this-&gt;assertEqual(strtolower(get_class($stest2)), &quot;supertest&quot;);
 
 			$utest2 = $Test-&gt;find_by_dummy(&quot;UltraDummy&quot;);
-			$this-&gt;assertEqual($utest2-&gt;type, &quot;UltraTest&quot;);
+			$this-&gt;assertEqual(strtolower($utest2-&gt;type), &quot;ultratest&quot;);
 			$this-&gt;assertEqual(strtolower(get_class($utest2)), &quot;ultratest&quot;);
 
 			$atest2 = $Test-&gt;find_by_dummy(&quot;AutoDummy&quot;);
-			$this-&gt;assertEqual($atest2-&gt;type, &quot;AutoTest&quot;);
+			$this-&gt;assertEqual(strtolower($atest2-&gt;type), &quot;autotest&quot;);
 			$this-&gt;assertEqual(strtolower(get_class($atest2)), &quot;autotest&quot;);
 		}
 	}</diff>
      <filename>tests/TestSTI.class.php</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>384db5b4deaceea08892417e5c3865adb3591742</id>
    </parent>
  </parents>
  <author>
    <name>Kai Krakow</name>
    <email>kk@netactive.de</email>
  </author>
  <url>http://github.com/kakra/adodbrecord/commit/91a972cf5e187619c1d7420a58c078b574ede05b</url>
  <id>91a972cf5e187619c1d7420a58c078b574ede05b</id>
  <committed-date>2009-02-04T02:39:39-08:00</committed-date>
  <authored-date>2009-02-04T02:39:39-08:00</authored-date>
  <message>Fix STI with PHP4

&quot;type&quot; column must not be set when inserting the base class itself.</message>
  <tree>0e9cfbeb537d3c199da972630b0129091c6be80d</tree>
  <committer>
    <name>Kai Krakow</name>
    <email>kk@netactive.de</email>
  </committer>
</commit>
