abergquist (181) [Avatar] Offline
#1
Based on the following text (found in Footnote 2 on p. 115 [p. 119 of .PDF]):

We’ll determine the validity of the post by setting a maximum length here; I’ve arbitrarily picked 160 to demonstrate usage, but a more realistic limit would account for the fact that users sometimes want posts to be quite long


the following two (2) changes need to be made:

a) the following code code in Listing 5.6 (on p. 114 [p. 118 of the .PDF):

valid: content.length >= 300,


needs to be replaced with the following code:

valid: content.length < 300,


b) "160" needs to be replaced with "300" in Footnote 2 on p. 115 (p. 119 of .PDF):

We’ll determine the validity of the post by setting a maximum length here; I’ve arbitrarily picked 160 to demonstrate usage, but a more realistic limit would account for the fact that users sometimes want posts to be quite long

mark (53) [Avatar] Offline
#2
Thanks for catching this! smilie