class Encoder {

    public static boolean matches(String rawPassword, String encodedPassword) {
        try {
            return bCryptPasswordEncoder.matches(rawPassword, encodedPassword);
        } catch (Exception e) {
            LOG.error("password match check failed because of: " + e.getMessage());
        }
        return false;
    }

}