Skip to content

Commit

Permalink
refactor: mv UserBannedException & FileSizeException to exception…
Browse files Browse the repository at this point in the history
…/common
  • Loading branch information
ShiinaKin committed Oct 12, 2024
1 parent 5809304 commit 80aa7c1
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import io.sakurasou.controller.vo.CommonResponse
import io.sakurasou.controller.vo.ImagePageVO
import io.sakurasou.controller.vo.ImageVO
import io.sakurasou.controller.vo.PageResult
import io.sakurasou.exception.controller.param.FileSizeException
import io.sakurasou.extension.pageRequest
import io.sakurasou.plugins.AuthorizationPlugin
import io.sakurasou.service.image.ImageService
Expand Down Expand Up @@ -73,9 +72,6 @@ private fun Route.imageSelfUpload(controller: ImageController) {
{
val contentLength = call.request.header(HttpHeaders.ContentLength)?.toIntOrNull() ?: 0

if (contentLength < 0 || TODO("less than Group Limit")) {
throw FileSizeException()
}

var fileDescription = ""
var fileName = ""
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.sakurasou.exception.controller.param
package io.sakurasou.exception.common

import io.sakurasou.exception.ServiceThrowable

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.sakurasou.exception.controller.access
package io.sakurasou.exception.common

import io.sakurasou.exception.ServiceThrowable

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package io.sakurasou.service.auth

import at.favre.lib.crypto.bcrypt.BCrypt
import io.sakurasou.controller.request.UserLoginRequest
import io.sakurasou.exception.controller.access.UserBannedException
import io.sakurasou.exception.common.UserBannedException
import io.sakurasou.exception.controller.status.UnauthorizedAccessException
import io.sakurasou.exception.service.user.UserNotFoundException
import io.sakurasou.model.DatabaseSingleton.dbQuery
Expand Down

0 comments on commit 80aa7c1

Please sign in to comment.