Skip to content

Commit 2325834

Browse files
committed
Remove unneeded parameter from Calendar.PrintYear
1 parent b8511ea commit 2325834

4 files changed

Lines changed: 9 additions & 10 deletions

File tree

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
<groupId>org.fross</groupId>
55
<artifactId>cal</artifactId>
6-
<version>2.4.4</version>
6+
<version>2.4.5</version>
77
<packaging>jar</packaging>
88

99
<name>cal</name>

snap/snapcraft.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: fcal
2-
version: '2.4.4'
2+
version: '2.4.5'
33
summary: Command line calendar display
44
description: |
55
fCal is a command line calendar utility. It will display a

src/main/java/org/fross/cal/Calendar.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ public class Calendar {
3939
static protected final int DEFAULT_CALS_PER_ROW = 3;
4040
static protected final int CALENDARWIDTH = 20;
4141
static protected final int SPACESBETWEENCALS = 2;
42-
static protected final String[] MONTHLIST = { "", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November",
43-
"December" };
42+
static protected final String[] MONTHLIST = { "", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October",
43+
"November", "December" };
4444
static protected final Color TODAYHIGHLIGHT_FG = Ansi.Color.WHITE;
4545
static protected final Color TODAYHIGHLIGHT_BG = Ansi.Color.BLUE;
4646

@@ -126,10 +126,9 @@ public static void printMonth(int month, int year) {
126126
/**
127127
* printYear(): Print the entire year
128128
*
129-
* @param month
130129
* @param year
131130
*/
132-
public static void printYear(int month, int year) {
131+
public static void printYear(int year) {
133132
String[] days = new String[6];
134133
String[] dayrows = new String[6];
135134
int i, j, k;

src/main/java/org/fross/cal/Main.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -97,16 +97,16 @@ public static void main(String[] args) {
9797
// Display the calendars
9898
Output.println("");
9999
switch (CommandLineArgs.cli.clMonthAndOrYear.size()) {
100-
100+
101101
// No month or year provided
102102
case 0:
103-
Calendar.printYear(CommandLineArgs.queryMonthToUse(), CommandLineArgs.queryYearToUse());
103+
Calendar.printYear(CommandLineArgs.queryYearToUse());
104104
break;
105105

106-
// A month or year was given. Assume it's a month if it's 1-12
106+
// A month or year was given. Assume it's a month if it's 1-12
107107
case 1:
108108
if (Integer.parseInt(CommandLineArgs.cli.clMonthAndOrYear.get(0)) > 12) {
109-
Calendar.printYear(CommandLineArgs.queryMonthToUse(), CommandLineArgs.queryYearToUse());
109+
Calendar.printYear(CommandLineArgs.queryYearToUse());
110110
} else {
111111
Calendar.printMonth(CommandLineArgs.queryMonthToUse(), CommandLineArgs.queryYearToUse());
112112
}

0 commit comments

Comments
 (0)