Skip to content

Commit

Permalink
updated
Browse files Browse the repository at this point in the history
  • Loading branch information
MikhaelOrteza committed Dec 3, 2023
1 parent 25c4335 commit 3aabaa3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/app/MainFile.java
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ private static void setUpTempUser(InMemoryCurrentUserDAO currentUserDAO, FileUse
GetCurrentUserViewModel getCurrentUserViewModel) throws IOException {
CommonUserFactory userFactory = new CommonUserFactory();
CommonLocationFactory locationFactory = new CommonLocationFactory();
Location temporaryLocation = locationFactory.makeLocation("(50,-75)");
Location temporaryLocation = locationFactory.makeLocation("(43.664486,-79.399689)");
User temporaryUser = userFactory.create("username","123",5,"m","contact");
temporaryUser.setLocation(temporaryLocation);
currentUserDAO.changeUser(temporaryUser);
Expand Down
2 changes: 1 addition & 1 deletion src/data_access/CoordinatesFromIP.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class CoordinatesFromIP implements GetCoordinatesIP {
* @throws IOException error occurs with the api call. Here, empty coordinates would be returned.
*/
@Override
public String[] getCoordinates() throws IOException {
public String[] getCoordinates() throws IOException {
String[] result = {};
try {
URL url = new URL("http://ip-api.com/csv/");
Expand Down
3 changes: 1 addition & 2 deletions src/view/HomeView.java
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,7 @@ private void CreateEvent_BUTTONActionPerformed(java.awt.event.ActionEvent evt) t
private void SearchEvent_BUTTONActionPerformed(java.awt.event.ActionEvent evt) throws IOException {
if (evt.getSource().equals(SearchEvent_BUTTON)) {
try {
LocationFactory factory = new CommonLocationFactory();
Location userLocation = factory.makeLocation("(43.665510,-79.387280)");
String[] userLocation = getCurrentUserViewModel.getState().getUserCoordinates();
searchNearbyController.execute(userLocation);

} catch (IOException e) {
Expand Down

0 comments on commit 3aabaa3

Please sign in to comment.