redbitcz / simpleshop-wp-plugin

SimpleShop Wordpress Plugin
https://www.simpleshop.cz/category/wordpress-plugin/
Other
2 stars 1 forks source link

Opravy drobných chyb #6

Closed jakubboucek closed 6 years ago

jakubboucek commented 6 years ago

Opravy zjevných chyb

BC break: Ne

jakubboucek commented 6 years ago

Ano, to mám ověřené, short ternary je od 5.3: https://secure.php.net/manual/en/language.operators.comparison.php#language.operators.comparison.ternary

Vyfakturuj-cz commented 6 years ago

Ale projde i kdyz tam neni promenna? Podminka ? true : false; Projde, ale myslim ze s timto je v 5.3 problem: Podminka ? true; Podminka ? : false;

Dne po 3. zář 2018 6:35 uživatel Jakub Bouček notifications@github.com napsal:

Ano, to mám ověřené, short ternary je od 5.3: https://secure.php.net/manual/en/language.operators.comparison.php#language.operators.comparison.ternary

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/redbitcz/simpleshop-wp-plugin/pull/6#issuecomment-417997877, or mute the thread https://github.com/notifications/unsubscribe-auth/ATtKn34jJp5rCKYjrbTI0uNNzEM2_dojks5uXLGZgaJpZM4WW3hZ .

jakubboucek commented 6 years ago

Ano :)

Ternary operator je:

conditions ? true : false`

Short ternary operator je právě to zkrácené:

conditions ?: false`