This commit is contained in:
Lev
2021-09-03 23:23:57 -05:00
parent 83c9c6a490
commit 2a5a306ace
3 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,13 @@
try
{
verifyUser();
console.log("After verifyUser");
}
catch (exception)
{
console.log("Exception caught");
console.log("Name: " + exception.name); // Type of exception
console.log("Message: " + exception.message);
}
console.log("I'm still running..");

View File

@ -0,0 +1,17 @@
function verifyUser(username, password)
{
// code here
throw{name:"DatabaseError", message: "Could not connect to database"}
}
try
{
verifyUser();
console.log("After verifyUser");
}
catch (exception)
{
console.log("Exception caught");
console.log("Name: " + exception.name); // Type of exception
console.log("Message: " + exception.message);
}

View File

@ -0,0 +1,20 @@
Initialize in the project folder
git init
Get the git status (Name of Branch, Commit section, Stating section)
git status
Add a file to the staging area
git add filename.txt
Remove a file from the staging area
git rm filename.txt
Commit a file (all -a, -m Message)
git commit -a -m "My message"
Undo a commit
git --amend
Show commit log
git log