THE HAGUE, Netherlands — An Amsterdam appeals court upheld Monday the terror conviction of an Afghan asylum-seeker who stabbed two American tourists, seriously injuring them, at Amsterdam's main railway station in 2018.

The court said in a statement that judges slightly reduced the sentence of the attacker, who has been identified only as Jawed S., from nearly 27 years to 25 years based on sentences in similar cases and on his young age.

The man, who is now 21, was convicted of attempted murder with a terrorist motive just over a year ago. The court said he took a train from Germany to the Dutch capital to avenge what he perceived as insults to Islam and didn't know his victims were Americans.

"The appeals court calls it a cowardly attack," it said in a statement. "It is thanks to the very fast response of the police that there weren't more victims."

Police officers shot the attacker within 10 seconds of the attack on Aug. 31, 2018.

The court said that the attacker only expressed remorse during the appeals case. It said judges were unconvinced by his sincerity "and saw it as a way to reduce his sentence."

The two American victims were able to follow the appeals hearing via a video link. The attacker was ordered to pay them a total of nearly 3 million euros ($3.55 million) in damages.