diff --git a/docs/UserGuide.md b/docs/UserGuide.md
index 3902bf8c2da..810f6eeb68c 100644
--- a/docs/UserGuide.md
+++ b/docs/UserGuide.md
@@ -170,7 +170,7 @@ MediCLI is operated using typed commands to the command line interface (CLI). Do
### Quick Tutorial on a Sample Use Case
-1. Type the command in the command box and press Enter to execute it. e.g. typing **`help`** and pressing Enter will open the help window.
'
+1. Type the command in the command box and press Enter to execute it. e.g. typing **`help`** and pressing Enter will open the help window.
:exclamation: **DANGER**: If you are using a PDF version of this document, be careful when copying and pasting commands that span multiple lines as space characters surrounding line breaks may be omitted when copied over to the application.
diff --git a/src/main/java/seedu/address/logic/commands/EditAppointmentCommand.java b/src/main/java/seedu/address/logic/commands/EditAppointmentCommand.java
index 4972a4d664b..19ec65e7dae 100644
--- a/src/main/java/seedu/address/logic/commands/EditAppointmentCommand.java
+++ b/src/main/java/seedu/address/logic/commands/EditAppointmentCommand.java
@@ -148,6 +148,9 @@ public EditAppointmentDescriptor() {}
* A defensive copy of {@code tags} is used internally.
*/
public EditAppointmentDescriptor(EditAppointmentDescriptor toCopy) {
+ if (toCopy == null) { // Defensive Coding
+ throw new IllegalArgumentException();
+ }
setDateTime(toCopy.apptdatetime);
setDoctorNric(toCopy.doctorNric);
setPatientNric(toCopy.patientNric);
diff --git a/src/main/java/seedu/address/logic/commands/EditCommand.java b/src/main/java/seedu/address/logic/commands/EditCommand.java
index 20fddcc592b..1baba51a002 100644
--- a/src/main/java/seedu/address/logic/commands/EditCommand.java
+++ b/src/main/java/seedu/address/logic/commands/EditCommand.java
@@ -184,6 +184,9 @@ public EditPersonDescriptor() {
* A defensive copy of {@code tags} is used internally.
*/
public EditPersonDescriptor(EditPersonDescriptor toCopy) {
+ if (toCopy == null) { // Defensive Coding
+ throw new IllegalArgumentException();
+ }
setName(toCopy.name);
setPhone(toCopy.phone);
setNric(toCopy.nric);
diff --git a/src/test/java/seedu/address/logic/LogicManagerTest.java b/src/test/java/seedu/address/logic/LogicManagerTest.java
index 29b958be01a..bae99b8cea8 100644
--- a/src/test/java/seedu/address/logic/LogicManagerTest.java
+++ b/src/test/java/seedu/address/logic/LogicManagerTest.java
@@ -30,12 +30,13 @@
import seedu.address.model.ModelManager;
import seedu.address.model.ReadOnlyAddressBook;
import seedu.address.model.UserPrefs;
-import seedu.address.model.appointment.Appointment;
-import seedu.address.model.appointment.AppointmentDateTime;
+import seedu.address.model.person.Doctor;
+import seedu.address.model.person.Patient;
import seedu.address.model.person.Person;
import seedu.address.storage.JsonAddressBookStorage;
import seedu.address.storage.JsonUserPrefsStorage;
import seedu.address.storage.StorageManager;
+import seedu.address.testutil.AppointmentBuilder;
import seedu.address.testutil.PatientBuilder;
public class LogicManagerTest {
private static final IOException DUMMY_IO_EXCEPTION = new IOException("dummy IO exception");
@@ -100,8 +101,8 @@ public void getFilteredAppointmentList_modifyList_throwsUnsupportedOperationExce
public void getAppointmentList_getList_listIsNotNull() throws ParseException {
model.addPerson(ALICE);
model.addPerson(BROWN);
- model.addAppointment(
- new Appointment(BROWN.getNric(), ALICE.getNric(), new AppointmentDateTime("2024-11-11 11:02"), false));
+ model.addAppointment(new AppointmentBuilder().withDoctor((Doctor) BROWN)
+ .withPatient((Patient) ALICE).withDateTime("2024-11-11 11:02").build());
assertTrue(model.getFilteredAppointmentList() != null);
assertTrue(model.getFilteredAppointmentList().size() == 1);
}