package com.eactive.httpmockserver.config;

import com.eactive.httpmockserver.common.util.SecurityUtil;
import org.springframework.data.domain.AuditorAware;

import java.util.Optional;

public class AuditorAwareImpl implements AuditorAware<String> {

    @Override
    public Optional<String> getCurrentAuditor() {
        return Optional.ofNullable(SecurityUtil.getCurrentUserEsntlId());
    }

}