Mark Bonafe

Common Sense is Here

<August 2008>
SuMoTuWeThFrSa
272829303112
3456789
10111213141516
17181920212223
24252627282930
31123456


Navigation

bloggers

C#

Subscriptions



Wednesday, October 13, 2004 - Posts

You've Got to be Kidding

I swear sometimes it's just not worth comming into work.  Everyday, I get so called updates to the code base.  The changes are made by people in Maintenance (I'm in Development).  And everyday I find something completely rediculous.  Normally, it's something mundane like changing this:

deptName = value;

to this:

this.deptName = value;

Then today I found this fine little nugget.  This perfectly fine property:

public string ApprovedByUserName
{
    get
    {
        if (this.ApprovedBy > 0)
        {
            Users user = new Users();
            user.UserId = this.ApprovedBy;
            user = (Users)StoreFront.Instance.Get(user);
            return user.DisplayName;
        }
        else
        {
            return "";
        }
    }
}

Was rewritten to this:

public string ApprovedByUserName
{
    get
    {
        string displayName = String.Empty;

        bool result = (this.ApprovedBy > 0);

        switch (result)
        {
            case true:
                Users user  = new Users();
                user.UserId = this.ApprovedBy;
                user        = (Users)StoreFront.Instance.Get(user);
                displayName = user.DisplayName;                       
                break;
               
            case false:
                displayName = String.Empty;
                break;
        }

        return displayName;
    }
}


??What is this??  I have to put up with changes like this on a daily basis.  I've sent countless emails to the PM.  Every last one of them has been ignored. 

Usually, the changes don't break anything, but sometimes they do.  It's nerve wracking to see tested and approved code go through changes like this.  And it's all in the name of "beautification."

I don't know whether to laugh or cry.

posted Wednesday, October 13, 2004 11:19 AM by MarkBonafe




Powered by Dot Net Junkies, by Telligent Systems