renamed ReadFile to ReadTextFile
This commit is contained in:
parent
df38f0f62f
commit
4472808f20
2 changed files with 3 additions and 3 deletions
|
@ -137,7 +137,7 @@ func (c *CreateExecutor) createStatus(gtsClient *client.Client) error {
|
|||
case c.content != "":
|
||||
content = c.content
|
||||
case c.fromFile != "":
|
||||
content, err = utilities.ReadFile(c.fromFile)
|
||||
content, err = utilities.ReadTextFile(c.fromFile)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to get the status contents from %q: %w", c.fromFile, err)
|
||||
}
|
||||
|
|
|
@ -15,10 +15,10 @@ func ReadContents(text string) (string, error) {
|
|||
return text, nil
|
||||
}
|
||||
|
||||
return ReadFile(strings.TrimPrefix(text, filePrefix))
|
||||
return ReadTextFile(strings.TrimPrefix(text, filePrefix))
|
||||
}
|
||||
|
||||
func ReadFile(path string) (string, error) {
|
||||
func ReadTextFile(path string) (string, error) {
|
||||
file, err := os.Open(path)
|
||||
if err != nil {
|
||||
return "", fmt.Errorf("unable to open %q: %w", path, err)
|
||||
|
|
Loading…
Reference in a new issue