Telegram Messenger Inc. has been ordered to pay nearly $625,000 worth of legal fees to a small cryptocurrency firm that it sued over using the ‘GRAM’ crypto ticker and trademark.

In a Nov. 2 ruling, United States District Judge Charles Breyer granted $618,240 in attorney’s fees for 1,030.4 hours of work billed at $600 per hour. Lantah had requested compensation at a rate of $900 per hour, but the judge reduced the fees to meet the market rate for the services.

Lantah was also awarded $6,737.35 in costs that Telegram did not object to.

Lantah LLC has been defending the lawsuit since May 2018, after Telegram raised $1.7 billion through an initial coin offering for GRAMs — the native token of its Telegram Open Network blockchain platform.

Telegram accused the firm of common law trademark infringement, unfair competition and false designation of origin for trying to launch its own GRAM token. Lantah launched a counter suit in June 2018, asserting it had priority over the trademark through having filed an application with the U.S. Patent and Trademark office in late 2017.

However, the lawsuit was voluntarily dropped in August this year after Telegram abandoned the TON project in May, and settled a lawsuit filed by the U.S Securities and Exchange Commission in June.

The ruling mandated that Telegram’s motion to voluntarily dismiss the case was contingent on the firm paying all attorney fees incurred by Lantah in its defense. As the suit was dismissed without prejudice, Telegram has the right to file future claims against Lantah over the GRAM trademark.

In its settlement with the SEC, Telegram agreed to give the SEC notice before any digital issuances for the next three years.