Author: fabien
Date: 2010-04-01 15:56:17 +0200 (Thu, 01 Apr 2010)
New Revision: 28958
Modified:
branches/1.3/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
branches/1.4/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
Log:
[1.3, 1.4] fixed problem with return values for preDelete behavior for
SfPropelBehaviorSymfonyBehaviors (closes #7872)
Modified:
branches/1.3/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
===================================================================
---
branches/1.3/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
2010-04-01 12:50:29 UTC (rev 28957)
+++
branches/1.3/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
2010-04-01 13:56:17 UTC (rev 28958)
@@ -28,8 +28,10 @@
return <<<EOF
foreach
(sfMixer::getCallables('Base{$this->getTable()->getPhpName()}:delete:pre') as
\$callable)
{
- if (\$ret = call_user_func(\$callable, \$this, \$con))
+ if (call_user_func(\$callable, \$this, \$con))
{
+ \$con->commit();
+
return;
}
}
@@ -65,6 +67,8 @@
{
if (is_integer(\$affectedRows = call_user_func(\$callable, \$this, \$con)))
{
+ \$con->commit();
+
return \$affectedRows;
}
}
Modified:
branches/1.4/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
===================================================================
---
branches/1.4/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
2010-04-01 12:50:29 UTC (rev 28957)
+++
branches/1.4/lib/plugins/sfPropelPlugin/lib/behavior/SfPropelBehaviorSymfonyBehaviors.php
2010-04-01 13:56:17 UTC (rev 28958)
@@ -28,8 +28,10 @@
return <<<EOF
foreach
(sfMixer::getCallables('Base{$this->getTable()->getPhpName()}:delete:pre') as
\$callable)
{
- if (\$ret = call_user_func(\$callable, \$this, \$con))
+ if (call_user_func(\$callable, \$this, \$con))
{
+ \$con->commit();
+
return;
}
}
@@ -65,6 +67,8 @@
{
if (is_integer(\$affectedRows = call_user_func(\$callable, \$this, \$con)))
{
+ \$con->commit();
+
return \$affectedRows;
}
}
--
You received this message because you are subscribed to the Google Groups
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/symfony-svn?hl=en.