Skip to content

Commit

Permalink
Prevent member from checking other member station
Browse files Browse the repository at this point in the history
  • Loading branch information
Ygnas committed May 27, 2022
1 parent 8655600 commit 01c0f73
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/controllers/StationCtrl.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ public class StationCtrl extends Controller {
public static void index(Long id) {
Member member = Accounts.getLoggedInMember();
Station station = Station.findById(id);
if (!member.stations.contains(station)) redirect("/dashboard");
Logger.info("Station id = " + id);
render("station.html", station);
}
Expand Down

0 comments on commit 01c0f73

Please sign in to comment.