public static function translateWeekday($date, $locale = "en") {

        // Initialize.
        $template = __DIR__ . "/../Resources/translations/messages.%locale%.yml";
        $filename = str_replace("%locale%", $locale, $template);

        // Check if the filename exists.
        if (false === file_exists($filename)) {
            $filename = str_replace("%locale%", "en", $template);
        }

        // Parse the translations.
        $translations = Yaml::parse(file_get_contents($filename));

        // Return the weekday part translated.
        return str_ireplace(array_keys($translations["weekdays"]), array_values($translations["weekdays"]), $date);
    }