add the forward-slash back to the flask app. Something on the front end keeps inserting it :(
This commit is contained in:
		
							parent
							
								
									0650c89109
								
							
						
					
					
						commit
						91b610c342
					
				| @ -15,7 +15,7 @@ parser.add_argument('geometry', type=int, required=True, help='Number of faces o | ||||
| parser.add_argument('discard_lowest', type=str_to_bool, required=True, help='Whether to discard lowest roll') | ||||
| 
 | ||||
| 
 | ||||
| @namespace.route('')  # resolves to: /dice | ||||
| @namespace.route('/')  # resolves to: /dice or /dice/ | ||||
| class RollDice(Resource): | ||||
|     @namespace.expect(parser) | ||||
|     def get(self): | ||||
|  | ||||
| @ -1,7 +1,7 @@ | ||||
| import pytest | ||||
| from app import app | ||||
| 
 | ||||
| ROUTE = '/dice' | ||||
| ROUTE = '/dice/' | ||||
| 
 | ||||
| 
 | ||||
| @pytest.fixture | ||||
|  | ||||
| @ -12,7 +12,10 @@ window.onload = function () { | ||||
|             discard_lowest: discard | ||||
|         }); | ||||
| 
 | ||||
|         fetch(`${window.BASE_URL}/dice?${queryParams}`) | ||||
|         const urlToFetch = `${window.BASE_URL}/dice?${queryParams}`; | ||||
|         console.log(`URL to fetch: ${urlToFetch}`); | ||||
| 
 | ||||
|         fetch(urlToFetch) | ||||
|             .then(response => response.json()) | ||||
|             .then(data => { | ||||
|                 const resultsDiv = document.getElementById('results'); | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user