This repository was archived by the owner on Mar 23, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +13
-10
lines changed Expand file tree Collapse file tree 3 files changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -136,15 +136,15 @@ func (s *Server) handleCat(c *fiber.Ctx) error {
136136 return fiber .ErrBadRequest
137137 }
138138
139- ok , err := s .idx .Exist (cid )
140- if err != nil {
141- zap .S ().Errorf ("idx get err: %s" , err )
142- return err
143- }
144-
145- if ! ok {
146- return fiber .ErrBadRequest
147- }
139+ // ok, err := s.idx.Exist(cid)
140+ // if err != nil {
141+ // zap.S().Errorf("idx get err: %s", err)
142+ // return err
143+ // }
144+
145+ // if !ok {
146+ // return fiber.ErrBadRequest
147+ // }
148148
149149 path := filepath .Join (cid , c .Params ("file" ))
150150 src , err := s .ipc .CatStream (path )
Original file line number Diff line number Diff line change @@ -99,4 +99,7 @@ func (s *Server) registerRoutes(app *fiber.App) {
9999 app .Get ("/:cid/raw/:file" , s .handleCat )
100100
101101 app .Static ("/" , "./dist" )
102+ app .Get ("/*" , func (c * fiber.Ctx ) error {
103+ return c .SendFile ("./dist/index.html" )
104+ })
102105}
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ function App() {
2525 < div tw = 'min-h-[80vh]' >
2626 < Sections />
2727 </ div >
28- < aside tw = 'mt -5 text-center' >
28+ < aside tw = 'my -5 text-center' >
2929 < span tw = 'italic' > ©2021 Shoujo/IO, < a href = "https://github.com/mayocream/pastebin-ipfs/issues" > Feedback</ a > </ span >
3030 </ aside >
3131 </ >
You can’t perform that action at this time.
0 commit comments