分离注册登录接口

This commit is contained in:
2025-09-08 20:16:29 +08:00
parent a33eeef27e
commit 1b857e1493
8 changed files with 115 additions and 165 deletions

View File

@@ -8,7 +8,6 @@ import com.onekeycall.videotablet.utils.SecureIdGenerator;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;
import org.springframework.security.crypto.password.PasswordEncoder;
@@ -92,7 +91,7 @@ public class UserService implements UserDetailsService {
}
@Override
public UserDetails loadUserByUsername(String userId) throws UsernameNotFoundException {
public User loadUserByUsername(String userId) throws UsernameNotFoundException {
return userRepository.findByUserId(userId)
.orElseThrow(() -> new UsernameNotFoundException("User not found with userId: " + userId));
}