File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -702,8 +702,8 @@ axes.calcTicks = function calcTicks(ax, opts) {
702702 var maxRange = Math . max ( rng [ 0 ] , rng [ 1 ] ) ;
703703
704704 var definedDelta ;
705- var tickformat = axes . getTickFormat ( ax ) ; // don't use ax.tickformat directly
706- if ( isPeriod ) {
705+ var tickformat = axes . getTickFormat ( ax ) ;
706+ if ( isPeriod && tickformat ) {
707707 if (
708708 ! ( / % [ f L Q s S M H I p X ] / . test ( tickformat ) )
709709 // %f: microseconds as a decimal number [000000, 999999]
@@ -946,7 +946,8 @@ axes.autoTicks = function(ax, roughDTick) {
946946 // 2 or 3 days... but that's a weird enough case that we'll ignore it.
947947 ax . tick0 = Lib . dateTick0 ( ax . calendar , true ) ;
948948
949- if ( / % [ u V W ] / . test ( ax . tickformat ) ) { // should we use axes.getTickFormat(ax) instead here?
949+ var tickformat = axes . getTickFormat ( ax ) ;
950+ if ( / % [ u V W ] / . test ( tickformat ) ) { // should we use axes.getTickFormat(ax) instead here?
950951 // replace Sunday with Monday for ISO and Monday-based formats
951952 var len = ax . tick0 . length ;
952953 var lastD = + ax . tick0 [ len - 1 ] ;
You can’t perform that action at this time.
0 commit comments