Huddersfield Giants were wrong to sack Keith Mason, a judge has ruled.

Mason, 31, who played for the Giants for seven years, was sacked in October last year over a dodgy picture on his Twitter account.

After failing to overturn the decision on appeal he sued the club for wrongful dismissal.

Yesterday, after three days of evidence, a judge ruled he had been hard done by.

The court victory means the former Giants prop is in line for damages in the region of £167,000.

Reacting to the win, Mr Mason said he felt “justice had been served”.

The club launched disciplinary action against Mr Mason after a picture of a man’s backside was posted on his Twitter account.

It was in fact fellow Giants player, Scott Moore’s behind.

He had taken it on Mr Mason’s iPhone without his knowledge during the so-called Mad Monday end of season drinking session.

After he returned from the three-day drinking binge in September 2012, his then girlfriend Lauren Harwood found it on his phone while he was having a bath.

She posted it on Twitter without telling him, using his personal account.

The offensive image was put on Twitter on Tuesday, September 18 and remained there for almost 48 hours until Mr Mason deleted it.

But despite the club accepting that Ms Harwood had posted it to Twitter without Mr Mason’s knowledge he was still dismissed for gross misconduct two weeks later.

He was just one year into £95,000 per year, four-year contract at the time.

The club said he had brought it into disrepute by not deleting it soon enough.

Mr Mason said the club used the incident as a chance to fire him as they had wanted him to move to Wakefield Wildcats to free up space in their salary cap for new players Craig Kopczak and Stuart Fielden.

Yesterday at Leeds Crown Court, His Honour, Judge Andrew Saffman, ruled the club had been unfair in deciding the incident was gross misconduct.

He said it had been demonstrated that the club tolerated a ‘naked run’ associated with the Mad Monday celebrations and had not issued any formal warning to players in the past.

The judge also ruled that the player’s Twitter account was personal and was not “inextricably linked” to the Huddersfield Giants.

He said: “I had no difficulty in finding the claimant has established he was wrongfully dismissed even without considering the background issues of the club signing other players.

“The club knew (Mad Monday) happened every year but it did not put its foot down to stop it.”

Referring to the offensive tweet, he said: “When the error of his ways was pointed out, he set out to correct it.

“Therefore, I cannot accept he was deliberately flouting the terms of his contract.

“On the contrary, it may be seen as an effort of damage limitation.

“When all is said and done, the claimant was employed as a rugby player.

“The offensive tweet took place outside of the workplace.”

Judge Saffman applauded the club’s desire to retain “family values” but said it was clear it was “keen” to offload Mason to Wakefield Wildcats.

Speaking outside court, Mason, who now plays for Castleford Tigers, said: “I’m happy to get a bit of closure on this part of my life.

“It’s been really tough but justice has been served and I’m really happy.

“I’d like to thank my family for their support and my friends.

“I can put it behind me now and get on with my life.”

Keith’s solicitor, Richard Cramer, said: “It’s probably been one of the most challenging and difficult parts of his life.

“The proceedings were taken with a very heavy heart; there was an opportunity to resolve it very early on which was rejected.

“It’s disappointing that we got to this stage but we’ve been vindicated in what we did.”

Keith’s dad, who is also called Keith, slammed Giants’ chiefs for putting his son through hell.

He said: “He was never at fault for anything, he was blacklisted by the Giants’ supporters and it was wrong.

“He’s had a bad time and the people of Huddersfield should know what the club did to him, I hope it’s come out now.”

The costly legal defeat means the club is facing a total bill of more than £200,000 when court costs are included.

The judge has indicated Mr Mason will be in line for approximately £167,000 in damages and lost earnings before tax and other deductions.

Judge Saffman adjourned the case until early August for the two sides to negotiate a final number.

Giants’ chairman Ken Davy last night insisted the club had fought the Keith Mason case “to uphold standards”.

And he insisted he would do so again if the need arose.

Mr Davy was speaking minutes after a High Court judge ruled in favour of former player Keith Mason, who had taken action over the club for unfair dismissal.

The case centred on a cheeky photo on Mason’s phone and his Twitter account.

But the court heard the club had wanted to get rid of the forward.

Mr Davy said: “The Huddersfield Giants are a child-friendly, family-friendly, community club.

“In defending these standards and values we have disappointingly lost the case of unfair dismissal against a former player.

“It is a sad reflection on today’s society that this was the outcome.

“I am pleased we have stood up for our beliefs for our supporters and this great club and as long as I am chairman of the Giants we will continue to do that.”