The court's 5-4 order clears the way for Judge Juan M. Merchan to impose a sentence Friday on Trump