看板 Soft_Job 關於我們 聯絡資訊
public static function getRandomName($gender) { return 'Mary'; } Mike writes, "Oh, the things that I find in our codebase." "I have no idea who put this in, or why it was put in. But it's there, and it's somehow called in a few places. As tempted as I was to investigate how it was used, I figured I'd spare my sanity." Mike adds, "should there come a day that I need an actually random name, perhaps I'll look for getReallyRandomName." -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 123.195.16.113
Ting1024:XD 滿溫馨的 02/15 03:08
leicheong:然後TRWTF(TM)是即使$gender設成男性, 仍然會回傳Mary.. 02/15 09:14
leicheong:或者要hardcode的話, 選一個男女皆可用的名字會比較好.. 02/15 09:15
luciferii:瑪莉有夠衰 02/16 21:43
salagadoola:在裡面加一行 //FIXME 然後置之不理~ 02/16 22:11
rshadow:樓上XDDDD 02/16 22:24
antory:我遇過原廠的code過來內容有 //fix me,火都噴出來 02/16 23:19
Sany:不懂,為什麼寫fix me? 02/17 15:15
dingyuchi:有bug吧 02/17 15:35
Sany:就是只是說改掉他,然後什麼原因都沒說的意思嗎? 02/17 15:51
chengcti:就是他那時沒時間改.希望後面review時要記得改 02/17 15:56
chengcti:久而久之沒人 review 就... 放在那邊 release 出去了 02/17 15:56
Sany:原來如此 02/17 16:04