public
Last active — forked from dan-manges/gist:430424

  • Download Gist
gistfile1.builder
Ruby
1
def mask(x)y=x.dup;y[6,6]='*'*6;y;end

Ryan, This changes the referenced string and is not equivalent to Dan's. -Rob

added #dup in order to not mutate x

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.