lekt...@apache.org wrote:
> Author: lektran
> Date: Sat Feb 27 15:40:21 2010
> New Revision: 916973
> 
> URL: http://svn.apache.org/viewvc?rev=916973&view=rev
> Log:
> Minor code cleanup: removed unnecessary cast and changed how a static field 
> was being accessed
> 
> Modified:
>     
> ofbiz/trunk/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java
> 
> Modified: 
> ofbiz/trunk/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java
> URL: 
> http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java?rev=916973&r1=916972&r2=916973&view=diff
> ==============================================================================
> --- 
> ofbiz/trunk/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java
>  (original)
> +++ 
> ofbiz/trunk/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java
>  Sat Feb 27 15:40:21 2010
> @@ -385,7 +385,7 @@
>  
>      public static Transaction suspend() throws GenericTransactionException {
>          try {
> -            if (TransactionUtil.getStatus() != 
> TransactionUtil.STATUS_NO_TRANSACTION) {
> +            if (TransactionUtil.getStatus() != STATUS_NO_TRANSACTION) {
>                  TransactionManager txMgr = 
> TransactionFactory.getTransactionManager();
>                  if (txMgr != null) {
>                      
> pushTransactionBeginStackSave(clearTransactionBeginStack());

Yeah, this really grinds my gears.  FooUtil continually referring to
itself for static variables and methods.  It makes renaming/copying
the class more difficult.

There are lots of classes in ofbiz that follow this anti-pattern(I
think it is anti, anyways).

Reply via email to