question: public String removeAfter ( String original , String marker ) { int index = original . indexOf ( marker ) ; if ( index != - 1 ) { return original . substring ( 0 , index ) ; } return original ; }
target:  This method removes the end part of a string beginning at a specified marker.