Skip to content

Commit

Permalink
hard-code phetioType in StringProperty, see #116
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Nov 2, 2018
1 parent b8be5bd commit bdc63e6
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions js/StringProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,14 @@ define( function( require ) {
*/
function StringProperty( value, options ) {

options = _.extend( {
phetioType: PropertyIO( StringIO )
}, options );
options = options || {};

assert && assert( !options.valueType, 'valueType is set by StringProperty' );
options.valueType = 'string';

assert && assert( !options.hasOwnProperty( 'phetioType' ), 'phetioType is set by StringProperty' );
options.phetioType = PropertyIO( StringIO );

Property.call( this, value, options );
}

Expand Down

0 comments on commit bdc63e6

Please sign in to comment.