mirror of
https://github.com/UnlegitDqrk/Potato.git
synced 2025-10-02 14:40:14 +02:00
Fix compile-time error.
When throwing a NotDeliciousException, the "new" keyword wasn't being used, thus causing it to be interpreted as a method call
This commit is contained in:
@@ -24,7 +24,7 @@ public class Potato implements Tuber {
|
||||
public void prepare() throws NotDeliciousException {
|
||||
this.addCondiments("sour cream", "chives", "butter", "crumbled bacon", "grated cheese", "ketchup", "salt", "tabasco");
|
||||
this.listCondiments();
|
||||
if(!this.isDelicious()) throw NotDeliciousException();
|
||||
if(!this.isDelicious()) throw new NotDeliciousException();
|
||||
}
|
||||
|
||||
public void addCondiments(String... names) {
|
||||
|
Reference in New Issue
Block a user