Skip to content

Commit

Permalink
refactor: move interceptor package to web package
Browse files Browse the repository at this point in the history
  • Loading branch information
Quentin-Guillemin committed Sep 26, 2024
1 parent 502c5ce commit d76cb8f
Show file tree
Hide file tree
Showing 11 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@

package fr.recia.collabsoft.configuration;

import fr.recia.collabsoft.interceptor.SoffitInterceptor;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.SoffitInterceptor;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
import fr.recia.collabsoft.db.entity.User;
import fr.recia.collabsoft.db.repository.AssociatedAppRepository;
import fr.recia.collabsoft.db.repository.FileRepository;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.enums.Authority;
import fr.recia.collabsoft.model.pojo.JsonFileBody;
import lombok.extern.slf4j.Slf4j;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
import fr.recia.collabsoft.db.entity.QMetadata;
import fr.recia.collabsoft.db.entity.User;
import fr.recia.collabsoft.db.repository.MetadataRepository;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.enums.Authority;
import fr.recia.collabsoft.model.pojo.JsonMetadataBody;
import lombok.extern.slf4j.Slf4j;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import fr.recia.collabsoft.db.entity.QUser;
import fr.recia.collabsoft.db.entity.User;
import fr.recia.collabsoft.db.repository.UserRepository;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
* limitations under the License.
*/

package fr.recia.collabsoft.interceptor;
package fr.recia.collabsoft.web.interceptor;

import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.ObjectMapper;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import lombok.extern.slf4j.Slf4j;
import org.springframework.http.HttpStatus;
import org.springframework.web.servlet.HandlerInterceptor;
Expand All @@ -41,7 +41,7 @@ public SoffitInterceptor(SoffitHolder soffitHolder) {
}

@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) {
String path = request.getRequestURI().substring(request.getContextPath().length());

if (path.startsWith("/api")) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package fr.recia.collabsoft.interceptor.bean;
package fr.recia.collabsoft.web.interceptor.bean;

import lombok.Data;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

import fr.recia.collabsoft.db.entity.Collaboration;
import fr.recia.collabsoft.db.enums.Role;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.pojo.JsonCollaborationBody;
import fr.recia.collabsoft.test.DatabaseUtils;
import org.junit.jupiter.api.AfterEach;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package fr.recia.collabsoft.service.db;

import fr.recia.collabsoft.db.entity.FileHistory;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.pojo.JsonHistoryBody;
import fr.recia.collabsoft.test.DatabaseUtils;
import org.junit.jupiter.api.AfterEach;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package fr.recia.collabsoft.service.db;

import fr.recia.collabsoft.db.entity.File;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.enums.Authority;
import fr.recia.collabsoft.model.pojo.JsonFileBody;
import fr.recia.collabsoft.test.DatabaseUtils;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

package fr.recia.collabsoft.service.db;

import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.model.pojo.JsonMetadataBody;
import fr.recia.collabsoft.test.DatabaseUtils;
import org.junit.jupiter.api.AfterEach;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package fr.recia.collabsoft.service.db;

import fr.recia.collabsoft.db.entity.User;
import fr.recia.collabsoft.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.web.interceptor.bean.SoffitHolder;
import fr.recia.collabsoft.test.DatabaseUtils;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
Expand Down

0 comments on commit d76cb8f

Please sign in to comment.