Skip to content

Commit 53f64f5

Browse files
author
chadcarlson
committed
Remove guard on variables() method
1 parent 4e4ce85 commit 53f64f5

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

platformshconfig/config.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -255,16 +255,12 @@ def variables(self):
255255
256256
If you're looking for a specific variable, the variable() method is a more robust option.
257257
This method is for classes where you want to scan the whole variables list looking for a pattern.
258+
It's valid for there to be no variables defined at all, so there's no guard for missing values.
258259
259260
Returns:
260261
The full variables dict.
261262
262263
"""
263-
264-
if not self._variablesDef:
265-
raise NotValidPlatformException(
266-
'No variables are defined. Are you sure you are running on Platform.sh?'
267-
)
268264
return self._variablesDef
269265

270266
def routes(self):

0 commit comments

Comments
 (0)