Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor code-base variable names and function definitions #9

Merged
merged 2 commits into from Nov 14, 2018

Conversation

BrianArch96
Copy link
Collaborator

Signed-off-by: Brian Archbold brianarchbold96@yahoo.ie

@BrianArch96 BrianArch96 changed the title make me superstar :))) refactor code-base variable names and function definitions Nov 14, 2018
String username = data[5];

GregorianCalendar date = new GregorianCalendar(year, month-1, day);
GregorianCalendar date = new GregorianCalendar(YEAR, MONTH-1, DAY);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are constants which should be passed into certain methods for GregorianCalendar to tell it what info you want etc. They don't actually give you the year, month and day

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I deleted those 3 lines by accident and then was getting errors to the variables not being recognised, my bad :)

import User.AccountFactory;
import User.Customer;
import User.Supervisor;
import User.*;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say you could leave in the individual imports, just to keep it consistent with the rest of the code, and in case something else gets added to the User package

import ThirdParty.Delivery.Delivery;
import java.awt.BorderLayout;
import java.awt.event.WindowEvent;
import ThirdParty.Delivery.*;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

@@ -262,18 +251,17 @@ private void LoginEmailActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FI
private void LoginButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_LoginButtonActionPerformed
email = LoginEmail.getText();
password = LoginPassword.getText();
boolean bool = false;
boolean validation = false;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isValid might be a better name

@@ -59,7 +58,7 @@ public void buyStock(String itemBought, int amountBought){
/**
*
* @param itemName Checks if Item is in warehouse.
* @return bool
* @return boolean indicating if shop an item
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uhh, what the fuck? 🤔

Signed-off-by: Brian Archbold <brianarchbold96@yahoo.ie>
Signed-off-by: Brian Archbold <brianarchbold96@yahoo.ie>
@BrianArch96 BrianArch96 merged commit fa3fe9c into master Nov 14, 2018
@BrianArch96
Copy link
Collaborator Author

Thanks for all the feedback :).
Much love :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants