mirror of
				https://github.com/soybeanjs/soybean-admin.git
				synced 2025-11-04 15:53:43 +08:00 
			
		
		
		
	fix(projects): check if init userInfo when initAuthRoute. fixed #680
This commit is contained in:
		@@ -176,6 +176,11 @@ export const useRouteStore = defineStore(SetupStoreId.Route, () => {
 | 
			
		||||
 | 
			
		||||
  /** Init auth route */
 | 
			
		||||
  async function initAuthRoute() {
 | 
			
		||||
    // check if user info is initialized
 | 
			
		||||
    if (!authStore.userInfo.userId) {
 | 
			
		||||
      await authStore.initUserInfo();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    if (authRouteMode.value === 'static') {
 | 
			
		||||
      initStaticAuthRoute();
 | 
			
		||||
    } else {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user