File tree Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -161,25 +161,24 @@ class TableEditColumn extends Component {
161
161
162
162
getInputRef = userRef => ref => {
163
163
this . inputRef = ref ;
164
- if ( typeof userRef === 'string' ) {
165
- throw new Error ( 'Ref must be a function' ) ;
166
- }
167
164
if ( Util . isFunction ( userRef ) ) {
168
165
userRef ( ref ) ;
166
+ } else if ( typeof userRef === 'string' ) {
167
+ throw new Error ( 'Ref must be a function' ) ;
169
168
}
170
169
}
171
170
172
- getHandleKeyPress = userHandler => e => {
171
+ getHandleKeyPress = customHandler => e => {
173
172
this . handleKeyPress ( e ) ;
174
- if ( Util . isFunction ( userHandler ) ) {
175
- userHandler ( e ) ;
173
+ if ( Util . isFunction ( customHandler ) ) {
174
+ customHandler ( e ) ;
176
175
}
177
176
}
178
177
179
- getHandleBlur = userHandler => e => {
178
+ getHandleBlur = customHandler => e => {
180
179
this . handleBlur ( e ) ;
181
- if ( Util . isFunction ( userHandler ) ) {
182
- userHandler ( e ) ;
180
+ if ( Util . isFunction ( customHandler ) ) {
181
+ customHandler ( e ) ;
183
182
}
184
183
}
185
184
@@ -202,7 +201,7 @@ class TableEditColumn extends Component {
202
201
let style = { position : 'relative' } ;
203
202
let { fieldValue } = this . props ;
204
203
let { className } = this . state ;
205
- // put placeholder if exist
204
+
206
205
if ( editable . placeholder ) {
207
206
attr . placeholder = editable . placeholder ;
208
207
/* eslint-disable no-console */
You can’t perform that action at this time.
0 commit comments